My Assistant
![]() ![]() |
|
|
Nov 20 2009, 04:03 AM
Post
#1
|
|
|
UtterAccess Guru Posts: 868 From: BKK |
Sorry to be a pest,
I've asked this question before about three years ago but I've completely forgotten how to do it. I have two combo boxes, lets say cbobox1 and cbobox2, I want cbobox2 to be disabled until cbobox1 has been completed with a value, I have a vague recollection of something like this but I'm not sure it's completely correct, the most obvious thing to do would be for me to try it but I wanted to ask the experts first, if that is ok? if cbobox1.value = null then me.cbobox2.enabled = false else me.cbobox2.enabled = true end sub Thanks for your time |
|
|
|
Nov 20 2009, 04:15 AM
Post
#2
|
|
|
UA Editor + Utterly Certified Posts: 22,722 From: Melton Mowbray,Leicestershire (U.K) |
Hi
Look to use the On Current event of the form.. Try this: CODE If IsNull(Me.ComboName) Then Me.cbobox2.enabled = False Else Me.cbobox2.enabled = True End If (IMG:http://www.utteraccess.com/forum/style_emoticons/default/thumbup.gif) |
|
|
|
Nov 20 2009, 04:35 AM
Post
#3
|
|
|
UtterAccess Guru Posts: 868 From: BKK |
thanks once again Larry
|
|
|
|
Nov 20 2009, 04:38 AM
Post
#4
|
|
|
UA Editor + Utterly Certified Posts: 22,722 From: Melton Mowbray,Leicestershire (U.K) |
|
|
|
|
Dec 4 2009, 10:25 AM
Post
#5
|
|
|
UtterAccess Guru Posts: 868 From: BKK |
Hi Larry,
Not sure, if you will still be following this thread but if you are or anybody else for that matter, I'm not quite sure which event I will use for another instance where I will use a combos value to display a message to a user. Basically a variation of the above: Private Sub Form_Current() If IsNull(Me.cboSelectSender) Then Me.cbooutstanding.Visible = True Else Me.cbooutstanding.Visible = False End If End Sub so a label (though I've labelled it cbooutstanding) will be displayed if there isn't any data inside the cboselectsender list |
|
|
|
![]() ![]() |
|
Go to Top · Lo-Fi Version | Time is now: 25th May 2013 - 04:41 PM |