G
Guest
Good Mornin
In my Access forms I am attempting to have Access software do a DSum from a table. Everything works fine as long as the DSum criteria is an actual number
This is the expression that the Wizard helped me create from within Access forms. I can only make this work as long as the account number is 123 and not a form field
=DSum("[Approved Expenses]!Cost","[Approved Expenses]","[Apporved Expenses]!Account="'123'"
where Approved Expenses is a table, Cost is the field I want to sum up when the Account field in the approved expenses table is the same as the account field in the Access form I am working with
However I need to make the DSum criteria (currently = 123) a variable which is a field that changes with every record in the form I am working on. The examples Microsoft provides are illustrated below. However how do I replace UK with a field in the form I am working with
DSum(expr, domain, [criteria]
DSum("[Freight]", "Orders", "[ShipCountry] = 'UK'")
In my Access forms I am attempting to have Access software do a DSum from a table. Everything works fine as long as the DSum criteria is an actual number
This is the expression that the Wizard helped me create from within Access forms. I can only make this work as long as the account number is 123 and not a form field
=DSum("[Approved Expenses]!Cost","[Approved Expenses]","[Apporved Expenses]!Account="'123'"
where Approved Expenses is a table, Cost is the field I want to sum up when the Account field in the approved expenses table is the same as the account field in the Access form I am working with
However I need to make the DSum criteria (currently = 123) a variable which is a field that changes with every record in the form I am working on. The examples Microsoft provides are illustrated below. However how do I replace UK with a field in the form I am working with
DSum(expr, domain, [criteria]
DSum("[Freight]", "Orders", "[ShipCountry] = 'UK'")