R
RNUSZ@OKDPS
I have a form that prompts user for selection of user ID and Name that will
then search database for records that contain the users initials. The form
requires user to select the user information from drop-down Combo list (Field
name Combo29). Combo29 field has two parts, User-Init and User-Name, as
columns 0 and 1 of combo29. On selection and change, form then executes "ON
CLICK " and searchs database for matching records, code follows:
Private Sub Combo29_Click()
Me.unbtxt_User_Init = Me.Combo29.Column(0)
Me.unbtxt_User_Name = Me.Combo29.Column(1)
MsgBox " Typist_Init_Text = " & Combo29.Column(0)
If DCount("*", "DPS_FR_CASE_RECORDS", "TYPIST_INIT_TXT LIKE """ &
Me.Combo29 & "*""") > 0 Then
MsgBox " Matching Case Records Found "
DoCmd.runMacro "FRM-Search-By-Typist"
Else
MsgBox "No Records To Show", vbOKOnly, "No Records"
Cancel = True
Me.Form!Combo29.SetFocus
End If
End Sub
Problem is, what use to work no longer works. Even though the table
DPS_FR_CASE_RECORDS have records that field TYPIST_INIT_TXT has user initials
of BD in the field, the program does not locate matching records, and fails
to display due to no records found.
Can someone help me with fixing this issue, it worked at one time.
TYPIST_INIT_TXT is defined as text field, 3 bytes. and I use the LIKE to do
like comparisons to assist in location of say value of BD.
Any clues on resolution would be greatly appreciated.
Thanks in advance
then search database for records that contain the users initials. The form
requires user to select the user information from drop-down Combo list (Field
name Combo29). Combo29 field has two parts, User-Init and User-Name, as
columns 0 and 1 of combo29. On selection and change, form then executes "ON
CLICK " and searchs database for matching records, code follows:
Private Sub Combo29_Click()
Me.unbtxt_User_Init = Me.Combo29.Column(0)
Me.unbtxt_User_Name = Me.Combo29.Column(1)
MsgBox " Typist_Init_Text = " & Combo29.Column(0)
If DCount("*", "DPS_FR_CASE_RECORDS", "TYPIST_INIT_TXT LIKE """ &
Me.Combo29 & "*""") > 0 Then
MsgBox " Matching Case Records Found "
DoCmd.runMacro "FRM-Search-By-Typist"
Else
MsgBox "No Records To Show", vbOKOnly, "No Records"
Cancel = True
Me.Form!Combo29.SetFocus
End If
End Sub
Problem is, what use to work no longer works. Even though the table
DPS_FR_CASE_RECORDS have records that field TYPIST_INIT_TXT has user initials
of BD in the field, the program does not locate matching records, and fails
to display due to no records found.
Can someone help me with fixing this issue, it worked at one time.
TYPIST_INIT_TXT is defined as text field, 3 bytes. and I use the LIKE to do
like comparisons to assist in location of say value of BD.
Any clues on resolution would be greatly appreciated.
Thanks in advance