how can we do this in combobox

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • muddasirmunir
    Contributor
    • Jan 2007
    • 284

    how can we do this in combobox

    i am using vb6
    what i want is i place a combo box on my form add some name to
    it
    now when we click on combo box on most right (down arrow) a drop
    down list apperat showning all the names

    can we call this drop down list on any other event like i want when
    the user type someting on a combobox the list appears with out clicking it
    with mouse.

    hope you understand what i mean
    thanks
  • lee123
    Contributor
    • Feb 2007
    • 556

    #2
    what do you mean, when you type in a letter the list will open up. i know there is a property in the property box (on your left) for the combo box for when you type in a letter what ever name you have in the combo box that's where it will begin it search (but it won't open up) i believe it under the "Style" event

    if this isn't what your talking about then post your question with a little more detail so someone else can answer you better

    lee123

    Comment

    • muddasirmunir
      Contributor
      • Jan 2007
      • 284

      #3
      simply my question is we have a combo box when click on

      most righ of the combo box list of all the items

      appears just below OK

      i just want that the same list should appear when the user get

      focus on combo box with out cliking it with mouse

      hope you understand
      Originally posted by lee123
      what do you mean, when you type in a letter the list will open up. i know there is a property in the property box (on your left) for the combo box for when you type in a letter what ever name you have in the combo box that's where it will begin it search (but it won't open up) i believe it under the "Style" event

      if this isn't what your talking about then post your question with a little more detail so someone else can answer you better

      lee123

      Comment

      • srswamy081
        New Member
        • Mar 2008
        • 1

        #4
        Originally posted by muddasirmunir
        simply my question is we have a combo box when click on

        most righ of the combo box list of all the items

        appears just below OK

        i just want that the same list should appear when the user get

        focus on combo box with out cliking it with mouse

        hope you understand

        Hi,

        I think In such cases u can use listbox instead of a combo box....

        Comment

        • QVeen72
          Recognized Expert Top Contributor
          • Oct 2006
          • 1445

          #5
          HI,

          In ComboBox's GotFocus event write this code:
          (It will automatically drop-down)

          [code=vb]
          Private Sub Combo1_GotFocus ()
          SendKeys "%{DOWN}"
          End Sub
          [/code]

          Regards
          Veena

          Comment

          • mafaisal
            New Member
            • Sep 2007
            • 142

            #6
            Hello

            Or U can use

            [code=vb]
            Private Sub Combo1_GotFocus ()
            SendKeys "{F4}"
            End Sub
            [/code]


            Faisal

            Comment

            Working...