G
Greg
Hi,
Thanks for the help on my previous question, it worked
very well.
I cannot get my third linked (dynamic) combo box to
refresh. I believe its in my code. The first two combo
boxes refresh everytime, but after I have gone through my
dropdowns more than once, nothing appears in the Jobsite
combo box.
I have 3 combo boxes in this order:
cboCust - Customer
cboDivision - Division
cboJobsite - Jobsite
I have one table - Company
I have 3 fields
CustID
Division
Jobsite
Here is my VB code:
Option Compare Database
Private Sub cboCust_AfterUpdate()
Dim strSearch As String
'For text IDs
strSearch = "[CustID] = " & Chr$(34) & Me![cboCust] &
Chr$(34)
'Find the record that matches the control.
Me.RecordsetClone.FindFirst strSearch
Me.Bookmark = Me.RecordsetClone.Bookmark
'requery the Division combox box so that it shows correct
information (given in the row source)
Me![cboDivision].Requery
Me.cboDivision.Enabled = True
Me![cboDivision].Value = "Select Division"
Me![cboJobsite].Requery
Me.cboJobsite.Enabled = True
Me![cboJobsite].Value = "Select Jobsite"
End Sub
Private Sub Form_Load()
Me.cboCust.Value = "select a customer"
Me.cboDivision.Enabled = False
Me.cboJobsite.Enabled = False
End Sub
Thank you,
Greg
Thanks for the help on my previous question, it worked
very well.
I cannot get my third linked (dynamic) combo box to
refresh. I believe its in my code. The first two combo
boxes refresh everytime, but after I have gone through my
dropdowns more than once, nothing appears in the Jobsite
combo box.
I have 3 combo boxes in this order:
cboCust - Customer
cboDivision - Division
cboJobsite - Jobsite
I have one table - Company
I have 3 fields
CustID
Division
Jobsite
Here is my VB code:
Option Compare Database
Private Sub cboCust_AfterUpdate()
Dim strSearch As String
'For text IDs
strSearch = "[CustID] = " & Chr$(34) & Me![cboCust] &
Chr$(34)
'Find the record that matches the control.
Me.RecordsetClone.FindFirst strSearch
Me.Bookmark = Me.RecordsetClone.Bookmark
'requery the Division combox box so that it shows correct
information (given in the row source)
Me![cboDivision].Requery
Me.cboDivision.Enabled = True
Me![cboDivision].Value = "Select Division"
Me![cboJobsite].Requery
Me.cboJobsite.Enabled = True
Me![cboJobsite].Value = "Select Jobsite"
End Sub
Private Sub Form_Load()
Me.cboCust.Value = "select a customer"
Me.cboDivision.Enabled = False
Me.cboJobsite.Enabled = False
End Sub
Thank you,
Greg