Results 1 to 5 of 5

Thread: [RESOLVED] ComboBox's

  1. #1

    Thread Starter
    Frenzied Member
    Join Date
    Mar 2006
    Location
    Pennsylvania
    Posts
    1,069

    Resolved [RESOLVED] ComboBox's

    Hey guys. Got a hopefully simple question. I have a DropDownStyle as DropDownList so you can only select things and not type but here's the problem:

    I have 2 combobox's and I want it so when you click one, the other one is blank so you don't get confused on which one you're using. However, 2ndcombobox.Text = ""; doesn't work cause it is DropDownList. Is there like a clear function or something?

    Thanks!

  2. #2
    Lively Member
    Join Date
    Jan 2006
    Posts
    66

    Re: ComboBox's

    This will work

    Code:
        comboBox1.Items.Clear();

  3. #3

    Thread Starter
    Frenzied Member
    Join Date
    Mar 2006
    Location
    Pennsylvania
    Posts
    1,069

    Re: ComboBox's

    Well.. This gets rid of all of them as well. I want to still be able to select them again. I don't want it to dissapear from the choices

  4. #4
    PoorPoster iPrank's Avatar
    Join Date
    Oct 2005
    Location
    In a black hole
    Posts
    2,729

    Re: ComboBox's

    PHP Code:
            void ComboBox1SelectedIndexChanged(object senderSystem.EventArgs e)
            {
                
    comboBox2.SelectedIndex=-1;
                
            } 
    Usefull VBF Threads/Posts I Found . My flickr page .
    "I love being married. It's so great to find that one special person you want to annoy for the rest of your life." - Rita Rudner


  5. #5

    Thread Starter
    Frenzied Member
    Join Date
    Mar 2006
    Location
    Pennsylvania
    Posts
    1,069

    Re: ComboBox's

    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