G Guest Dec 15, 2005 #1 Combo box lists all offices. Need to limit selection to one of three choices (offices in certain regions) in Option Group. How does one do that?
Combo box lists all offices. Need to limit selection to one of three choices (offices in certain regions) in Option Group. How does one do that?
M Michel Walsh Dec 16, 2005 #2 Hi, Change the rowsource property, in the gotFocus event of the combo box, as example. Dim str As string ' to hold temporary SQL statement str="SELECT fieldName FROM tableName WHERE RegionID=FORMS!FormName!FrameControlName" If str = Me.ComboBoxName.RowSource then 'do nothing Else Me.ComboBoxName.Rowsource= str ' that implicitly requeries the list End If Hoping it may help, Vanderghast, Access MVP
Hi, Change the rowsource property, in the gotFocus event of the combo box, as example. Dim str As string ' to hold temporary SQL statement str="SELECT fieldName FROM tableName WHERE RegionID=FORMS!FormName!FrameControlName" If str = Me.ComboBoxName.RowSource then 'do nothing Else Me.ComboBoxName.Rowsource= str ' that implicitly requeries the list End If Hoping it may help, Vanderghast, Access MVP
G Guest Dec 16, 2005 #3 thank you . . . I was still stuck. Beginner/Novice Acess user. I will try this and get back with you hopefully to tell you of my success! Tom
thank you . . . I was still stuck. Beginner/Novice Acess user. I will try this and get back with you hopefully to tell you of my success! Tom