If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
control visible
I tried to put a iif statement in a control visible attributte. It gives me
an error: "the text you entered isn't an item in list" PLease help. Thanks. |
#2
|
|||
|
|||
control visible
The Visible Property has two possible values: True and False. It doesn't
support expressions even if they evaluate to the valid values. You need to put code in an appropriate event to set it. Larry Linson Microsoft Access MVP "00MichaelJordan" wrote in message ... I tried to put a iif statement in a control visible attributte. It gives me an error: "the text you entered isn't an item in list" PLease help. Thanks. |
#3
|
|||
|
|||
control visible
On Thu, 14 Dec 2006 12:38:51 +0800, 00MichaelJordan wrote:
I tried to put a iif statement in a control visible attributte. It gives me an error: "the text you entered isn't an item in list" PLease help. Thanks. I would suggest you be a bit more specific. What does 'put an iif statement in a control visible attribute' mean? Post the actual iif statement, where you placed it, as well as what you expect to happen. -- Fred Please respond only to this newsgroup. I do not reply to personal e-mail |
#4
|
|||
|
|||
control visible
If you click in the property then press F1 it will bring up the help for that
item. You will find it is a boolean and only tru/false. To change it you need an event or macro to write to the control, "00MichaelJordan" wrote: I tried to put a iif statement in a control visible attributte. It gives me an error: "the text you entered isn't an item in list" PLease help. Thanks. |
#5
|
|||
|
|||
control visible
We really need to see your code, but as a general rule the most common place
to hide/show controls is in the Form_Current sub, i.e. Private Sub Form_Current() If Me.MyTextBox.Value = "no" Then MyCommandButton. Visible = False Else MyCommandButton. Visible = True End If End Sub If you needed to hide the control as soon as an event occurred, say a value was entered in MyTextBox, you could use something like this: Private Sub MyTextBox_BeforeUpdate(Cancel As Integer) If Me.MyTextBox.Value = "no" Then MyCommandButton. Visible = False End If End Sub If you do this, you will still need to use the first block of code above, in order to reset the visibilty when moving to another record. -- Message posted via AccessMonster.com http://www.accessmonster.com/Uwe/For...forms/200612/1 |
#6
|
|||
|
|||
control visible
I think this is helpful and I can deal with it from here. Thanks.
"missinglinq via AccessMonster.com" u28780@uwe wrote in message news:6ac00f03c278a@uwe... We really need to see your code, but as a general rule the most common place to hide/show controls is in the Form_Current sub, i.e. Private Sub Form_Current() If Me.MyTextBox.Value = "no" Then MyCommandButton. Visible = False Else MyCommandButton. Visible = True End If End Sub If you needed to hide the control as soon as an event occurred, say a value was entered in MyTextBox, you could use something like this: Private Sub MyTextBox_BeforeUpdate(Cancel As Integer) If Me.MyTextBox.Value = "no" Then MyCommandButton. Visible = False End If End Sub If you do this, you will still need to use the first block of code above, in order to reset the visibilty when moving to another record. -- Message posted via AccessMonster.com http://www.accessmonster.com/Uwe/For...forms/200612/1 |
Thread Tools | |
Display Modes | |
|
|