jeremy.lankenau
Registered User.
- Local time
- Today, 15:36
- Joined
- Feb 19, 2015
- Messages
- 32
Hi all,
Question regarding the Combo Box. I've searched all over the site (which I've used often when I've been stuck) and on google, and cannot seem to find the right answer to my issue:
I work in the HR Labor and Management Employee Relations field, and so we take various actions - Disciplinary, Performance, Reasonable Accomodation, Grievance's, etc.
I have a form - fAction, which contains a combobox Type_Of_Action. It is a value list which specifies the types of actions in the PP above. If Type_Of_Action has Disciplinary, selected, I have a hidden checkbox (DiscDecIssued) that is changes from hidden with 0 height to visible and 315.072 twips:
Private Sub Type_of_Action_Change()
If Type_of_Action.Value = "Disciplinary" Then
Me.DiscDecIssued.Visible = True
Me.DiscDecIssued.Height = 315.072
Me.Label81.Visible = True
Me.Label81.Height = 315.072
Else
Me.DiscDecIssued.Visible = False
Me.DiscDecIssued.Height = 0
Me.Label81.Visible = False
Me.Label81.Height = 0
End If
'1440 twips = 1 inch, so 315.072 twips = 0.2188 inches
End Sub
My problem is that since putting in this code, once a value is selected in the combo box's value list, whether "Disciplinary" or any of the various other values, the Combo Box will not display the selection until I tab off the Combo Box or click onto another field (the code itself works fine). Is there some VBA code I can put in (perhaps AfterUpdate() ) that will force the selected value to appear in the form before the user tabs off or clicks on another field?
I'd like to keep the DiscDecIssued hidden, because I only want it up if Disciplinary is selected. I have other hidden fields that appear if the DiscDecIssued is clicked that take the user through the logical steps (about 10 other fields), but these do not need to be visible unless Type_Of_Action is "Disciplinary" and DiscDecIssued is checked.
Thanks for your help!
Jeremy
Question regarding the Combo Box. I've searched all over the site (which I've used often when I've been stuck) and on google, and cannot seem to find the right answer to my issue:
I work in the HR Labor and Management Employee Relations field, and so we take various actions - Disciplinary, Performance, Reasonable Accomodation, Grievance's, etc.
I have a form - fAction, which contains a combobox Type_Of_Action. It is a value list which specifies the types of actions in the PP above. If Type_Of_Action has Disciplinary, selected, I have a hidden checkbox (DiscDecIssued) that is changes from hidden with 0 height to visible and 315.072 twips:
Private Sub Type_of_Action_Change()
If Type_of_Action.Value = "Disciplinary" Then
Me.DiscDecIssued.Visible = True
Me.DiscDecIssued.Height = 315.072
Me.Label81.Visible = True
Me.Label81.Height = 315.072
Else
Me.DiscDecIssued.Visible = False
Me.DiscDecIssued.Height = 0
Me.Label81.Visible = False
Me.Label81.Height = 0
End If
'1440 twips = 1 inch, so 315.072 twips = 0.2188 inches
End Sub
My problem is that since putting in this code, once a value is selected in the combo box's value list, whether "Disciplinary" or any of the various other values, the Combo Box will not display the selection until I tab off the Combo Box or click onto another field (the code itself works fine). Is there some VBA code I can put in (perhaps AfterUpdate() ) that will force the selected value to appear in the form before the user tabs off or clicks on another field?
I'd like to keep the DiscDecIssued hidden, because I only want it up if Disciplinary is selected. I have other hidden fields that appear if the DiscDecIssued is clicked that take the user through the logical steps (about 10 other fields), but these do not need to be visible unless Type_Of_Action is "Disciplinary" and DiscDecIssued is checked.
Thanks for your help!
Jeremy