Multiple fields visibility dependent on one field drop down list

  • Thread starter Thread starter Oldtimeplayer
  • Start date Start date
O

Oldtimeplayer

Hi,

I am trying to control multiple fields visibility on and off with a value
from a drop down list. Is it





Iff (dropdownlist.value=1 or 2 or 3.)then (Multiplefileds.visibility= on or
of)



Some thing lie that





Shariff
 
Your code might be something like:
Select Case Me.cboYourControlName
Case 1,2,3
Me.txtOtherControl.Visible = True
Case Else
Me.txtOtherControl.Visible = False
End Select
 
Hi,

I am trying to control multiple fields visibility on and off with a value
from a drop down list. Is it

Iff (dropdownlist.value=1 or 2 or 3.)then (Multiplefileds.visibility= on or
of)

Some thing lie that

Shariff

Assuming the only values in the combo box are integer numbers, i.e.
like 1,2,3,4,5,6, etc., then code the combo box AfterUpdate event and
the form's Current event:

[Control1].Visible = ComboName <4
[Control2].Visible = ComboName < 4
etc.

If the numbers can be decimals, 1, 1.5, 2, 2.25, etc. but you only
want 1, 2 or 3 to change the visibility of the controls, then use:
If ComboName = 1 Or ComboName = 2 Or ComboName = 3 then
[Control1].Visible = True
[Control2].Visible = True
Else
[Control1].Visible = False
[Control2].Visible = False
End If
 
i write this code for afterupdate [Event Procedure]

if [CaseStatus]="Full Case" Then
[Page114].Visible=True "the [Page114].Visible is set to Yes on the form"
Else
[Page114].Visible=False
End if

when i choose other then "Full Case" it works but if i go back and put "Full
Case" it will not turn it on again. why?

thanks



fredg said:
Hi,

I am trying to control multiple fields visibility on and off with a value
from a drop down list. Is it

Iff (dropdownlist.value=1 or 2 or 3.)then (Multiplefileds.visibility= on
or
of)

Some thing lie that

Shariff

Assuming the only values in the combo box are integer numbers, i.e.
like 1,2,3,4,5,6, etc., then code the combo box AfterUpdate event and
the form's Current event:

[Control1].Visible = ComboName <4
[Control2].Visible = ComboName < 4
etc.

If the numbers can be decimals, 1, 1.5, 2, 2.25, etc. but you only
want 1, 2 or 3 to change the visibility of the controls, then use:
If ComboName = 1 Or ComboName = 2 Or ComboName = 3 then
[Control1].Visible = True
[Control2].Visible = True
Else
[Control1].Visible = False
[Control2].Visible = False
End If
 
i write this code for afterupdate [Event Procedure]

if [CaseStatus]="Full Case" Then
[Page114].Visible=True "the [Page114].Visible is set to Yes on the form"
Else
[Page114].Visible=False
End if

when i choose other then "Full Case" it works but if i go back and put "Full
Case" it will not turn it on again. why?

thanks

fredg said:
Hi,

I am trying to control multiple fields visibility on and off with a value
from a drop down list. Is it

Iff (dropdownlist.value=1 or 2 or 3.)then (Multiplefileds.visibility= on
or
of)

Some thing lie that

Shariff

Assuming the only values in the combo box are integer numbers, i.e.
like 1,2,3,4,5,6, etc., then code the combo box AfterUpdate event and
the form's Current event:

[Control1].Visible = ComboName <4
[Control2].Visible = ComboName < 4
etc.

If the numbers can be decimals, 1, 1.5, 2, 2.25, etc. but you only
want 1, 2 or 3 to change the visibility of the controls, then use:
If ComboName = 1 Or ComboName = 2 Or ComboName = 3 then
[Control1].Visible = True
[Control2].Visible = True
Else
[Control1].Visible = False
[Control2].Visible = False
End If

I don't quite understand how your original question....
(Iff (dropdownlist.value=1 or 2 or 3. )
equates to this post's question....
( if [CaseStatus]="Full Case" Then)
I' m also having some difficulty figuring this line:
([Page114].Visible=True "the [Page114].Visible is set to Yes on the
form")
What is everything after True supposed to represent?

Did you place the same code in the control's AfterUpdate event as well
as the Form's Current event? Is the value of the bound column of the
combo box a number value or text?
 
Back
Top