harra
Registered User.
- Local time
- Today, 11:09
- Joined
- Mar 25, 2003
- Messages
- 29
Don't shoot me....
I made an error in the code that I provided (that's what I get for trying to work at the same time....lol)
I forgot that if you use the LIKE operator you MUST have the quotes. It's been awhile since I've done this and no longer have the original code that I wrote a couple years ago. I'm doing this from memory
I made an error in the code that I provided (that's what I get for trying to work at the same time....lol)
Code:
Dim defectNo As String
If Cancel = True Then
GoTo StandardExit
Else
SQL = "SELECT defect_Ref, Asset_ID, Mtce_code " & _
"FROM asset_defects " & _
"WHERE asset_defects.defect_Ref Like '" & Nz(Form_AM_asset_maint_form_EMS.txtDefectNo & "*", "*") & "'"
Me.RecordSource = SQL
End If
I forgot that if you use the LIKE operator you MUST have the quotes. It's been awhile since I've done this and no longer have the original code that I wrote a couple years ago. I'm doing this from memory
