Results 1 to 4 of 4

Thread: Quick question

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Jun 1999
    Location
    Calgary Alberta
    Posts
    359

    Post

    How do you set the selected item in a Combo Box? I'm using VBA but it should be the same as VB but I just don't seem to be doing it right.

  2. #2
    Guest

    Post

    If you want just the Text of the selected item, then you can take it from the Combo1.text property. If you need the Index of the selected item, then i dont know!, perhaps a recursive loop comparing the text to each item in the box.

    ------------------

    Wossname,
    Email me: wossnamex@talk21.com

  3. #3
    Former Admin/Moderator MartinLiss's Avatar
    Join Date
    Sep 1999
    Location
    San Jose, CA
    Posts
    33,175

    Post

    Set its ListIndex property.

    ------------------
    Marty

  4. #4

    Thread Starter
    Hyperactive Member
    Join Date
    Jun 1999
    Location
    Calgary Alberta
    Posts
    359

    Post

    Thanks Marty. That was it, I had been trying to use at the wrong place. In VBA you have to make sure the control has focus and I had it in the wrong place. Thanks.

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