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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Display field based on value of another.

Status
Not open for further replies.

mbrant123

Instructor
Feb 24, 2005
6
US
I have a continuous form where users select a value from a combo box. One of the options in the combo box is other. When users select other, I want another field to display but I want it to stay hidden for all other records.

I would appreciate in help with this problem.

Thanks Marion
 
With conditional formatting you may enable/disable the control.

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
I can only set the format properties based on a value. I want to set the visible property of another field only for that one record.
 
I can only set the format properties based on a value
The condition may be an expression

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
in the after update for the combo box do something like:
If me.cboMyField.column(0) = "Other" then
me.txtMySecondField.visible = True
else
me.txtMySecondField.visible = False
endif

'Substitute .column(1), .column(2), etc to correspond to the column in the combo box you want to use.
Good luck,
Rob
 
Thank you both for your post.

Rob I had already used code similar to yours but the problem is it displays the second field for all of the records not just the current one.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top