Results 1 to 3 of 3
  1. #1
    Lounger
    Join Date
    Jan 2001
    Location
    Rockville, MD USA
    Posts
    25
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Wild Cards (Access 2k)

    The following code is attached to a text box.

    Private Sub ANALYSISPRI_AfterUpdate()
    If ANALYSISPRI = "BAE" Then
    SendPriMessage Me
    End If
    End Sub

    My problem is that there may be other characters before and/or after BAE. I need to determine if the text box has been updated to include, anywhere in the possible string, BAE.

    Any suggestions?

  2. #2
    3 Star Lounger
    Join Date
    Jun 2001
    Location
    Maidstone, Kent, England
    Posts
    398
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Wild Cards (Access 2k)

    use the "InStr Function", You can find it in help :-)

    Peter

  3. #3
    3 Star Lounger
    Join Date
    Dec 2000
    Location
    USA
    Posts
    379
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Wild Cards (Access 2k)

    Try this as the test in your If statement: If Me![YourFieldName] Like "*BAE*" Then ...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •