theUN4GVEN
Programmer
I have a textbox on a form that I would like to contain the total sum of the price of parts for an individual client. The textbox should only contain the values for the prices of the parts for the current individual only. I have no problems obtaining this information through the following query:
SELECT sum(Quantity * Price)
FROM tblParts
WHERE InvoiceID = 23;
for one specific example where the InvoiceID = 23. I can run a query similar to this to fill a listbox based upon the current InvoiceID that the form is on, but cannot figure out how to do the same for a textbox. I have tried setting the textbox to a listbox but cannot get this to work when the current record changes. Any help would be appreciated explaining how to fill my textbox based upon this query where the invoice ID changes as the record changes.
Thank you!
SELECT sum(Quantity * Price)
FROM tblParts
WHERE InvoiceID = 23;
for one specific example where the InvoiceID = 23. I can run a query similar to this to fill a listbox based upon the current InvoiceID that the form is on, but cannot figure out how to do the same for a textbox. I have tried setting the textbox to a listbox but cannot get this to work when the current record changes. Any help would be appreciated explaining how to fill my textbox based upon this query where the invoice ID changes as the record changes.
Thank you!