Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Need Text Box to display filtered data.

Status
Not open for further replies.

Garyeag

Technical User
Mar 23, 2001
32
GB
I have an invoicing form on which a project may have up to 4 invoices. My form has project details and then four rows with details for each invoice. Details includes, project stage invoice relates to, the percentage of the total amount the invoice represents, invoice number, date, amount, vat, outstanding, etc.
All invoices are stored in one table, linked to project details on project number, with a one-to-many relationship.
How do I get my form to allocate the right invoice to the right row. Or rather, can I do it without using a sub-form.
It is easy using a sub-form, access does it automatically, but I finally written one query that contains all my data and overcome the million and one reasons that stopped it being updateable.
Having come so far, I want to allocate the right invoices to the right boxes.
Thus, Stage 1 invoices and invoices details go in row 1 text boxes, Stage 2 invoices etc.
The complicating factor is that not every project has 4 invoices. Some have 3, some only 2. The fourth invoice is actually supplemental and only occassionally used.
I have tried filtering but can't work out the syntax and the filter seems to apply to whole forms not individual fields/text boxes.
Insights appreciated.
 
You cannot change the data in a form when it is getting its data from a query.
here is what I do in that case.

Is have a text box or a popup that prompts the user for the data to change
Then I use VBA code to open the table and write that value into the table not back through the query
then refresh the form to reflect the change.

Clumsy to set up, YES.
but some times there is no other way.
DougP, MCP

Visit my WEB site to see how Bar-codes can help you be more productive
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top