| re: Help with the form
thank you very much!!! now i have another thing that is not working.
Is there something wrong with this statement, the part where Me.CN10.Enabled = True and Me.CN10.Enabled = False not working . lstSpecialist is the list box with dates of visit, I need to do the following : if there no dates in the list boxlstSpecialist then me.cn10(combo box) has to be gray out.
here is the code i have so far, but the part that has to disable combo box not working, i don't get any erroe message it just simply do not disabling combo box.
if Not IsNull(Me.lstSpecialist.RowSource) Then
sSQL = "SELECT dbo_tblNewVisitTracking.DOS FROM dbo_tblNewVisitTracking"
sSQL = sSQL & " Where dbo_tblNewVisitTracking.Sub_ID= '" & strSub_ID & "'"
sSQL = sSQL & " and dbo_tblNewVisitTracking.Visit_Type = 'Specialist'"
Me.lstSpecialist.RowSource = sSQL
Me.CN10.Enabled = True
Else
Me.lstSpecialist.Enabled = False
Me.lstSpecialist.Locked = True
Me.CN10.Enabled = False
Me.CN10 = "N/A"
Me.CN10.Locked = True
End If
thank you very much!
|