Results 1 to 5 of 5

Thread: Combobox SelectedIndexChanged

Hybrid View

  1. #1
    Fanatic Member pax's Avatar
    Join Date
    Mar 2001
    Location
    Denmark
    Posts
    840

    Re: Combobox SelectedIndexChanged

    You should do a check to see if SelectedIndex=-1 in the top of the SelectedIndexChanged method end exit if it is.
    I wish I could think of something witty to put in my sig...

    ...Currently using VS2013...

  2. #2

    Thread Starter
    Hyperactive Member
    Join Date
    Nov 2005
    Posts
    259

    Re: Combobox SelectedIndexChanged

    Thanks Pax. I tried that but since the records in the combobox get loaded and ordered alphabeticaly the IndexNumber starts out at 23 (The 23rd Record is (Abe) and then gets set to -1 as the form finishes loading, which is when the IndexXhanged gets fired.

    Doing it this way the 23 is what gets tested not the -1. And I can't test for a 23 all the time either because it is possible that a record will get added that will be Aarron and will move ahead of record 23.

    Anything else you can think of that I can try?

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