Results 1 to 2 of 2
  1. #1
    Join Date
    Feb 2003
    Posts
    6

    Lightbulb Unanswered: How to Search Combobox using SendMessage API

    How to Search for an item in the Combo Box using Send Message API function. i know how to use it for a list box, but it is not working for ComboBox even i change the parameter to "CB_FINDSTRING"
    Pls help me

  2. #2
    Join Date
    Nov 2002
    Location
    Ohio
    Posts
    90
    Hi svakula,

    If your API call isn't working...try this:

    On Error Resume Next
    yourcombobox.Text = yourstring
    On Error Goto 0
    If yourcombobox.Text = yourstring Then
    ' we found it - do something
    Else
    ' we didn't find it - do something
    EndIf

    It's almost as fast as the API call and you still have control over the "not found" condition.

    Good Luck,
    Bruce Baasch

Posting Permissions

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