Making texboxes invisible depending on the value in them (1 Viewer)

jer

Registered User.
Local time
Today, 21:58
Joined
Nov 21, 2011
Messages
109
Hi,
How do you make a textbox invisible depending on the value within then. I have a continous form which shows a textbox for tool numbers. However, when the tool number is "UNKNOWN" how do I make it that it substitutes in the Serial number of the Tool in its place?
Please help!!
Jer
 

Mr. B

"Doctor Access"
Local time
Today, 15:58
Joined
May 20, 2009
Messages
1,932
If you are using a query as the row source for your form then you can do what you want in the query not in the form. Just add a column to the query that using an IF statement to check the value of the ToolNumber and if that is "Unknown" then use the "SerialNumber" value else use the ToolNumber. Place this in a new column in the Field row of your query:
Code:
Tool: IIf([ToolNumber]="Unknown",[SerialNumber],[ToolNumber])

Just be sure to substitute the exact name of your fields in the appropriate references above.

This will create a field named Tool. Use this field in your form.
 

jer

Registered User.
Local time
Today, 21:58
Joined
Nov 21, 2011
Messages
109
Thanks Mr.B but I figured it out
Thanks anyway!!
 

Users who are viewing this thread

Top Bottom