CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Join Date
    Aug 1999
    Location
    Québec (Canada)
    Posts
    210

    Find Test "an" in string "you're an angel!"

    Give me an exemple to find text in string.

    Like "op" in "loop"

    Tanks!

    Redg


  2. #2
    Join Date
    May 1999
    Location
    Oxford UK
    Posts
    1,459

    Re: Find Test "an" in string "you're an angel!"

    How about :


    Dim sString as string
    '
    sString = "Chris Was Here"
    '
    If InStr(1, sString, "Here") > 0 then
    MsgBox "Found It"
    End If
    '
    ' or...
    '
    If sString Like "*Here*" then
    MsgBox "Found It"
    End If





    Chris Eastwood

    CodeGuru - the website for developers
    http://codeguru.developer.com/vb

Posting Permissions

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





Click Here to Expand Forum to Full Width

Featured