Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. Dropdownlist Shows defaultvalue when bound to sqldatasource.

Dropdownlist Shows defaultvalue when bound to sqldatasource.

Scheduled Pinned Locked Moved ASP.NET
tutorial
4 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    Asif Rehman
    wrote on last edited by
    #1

    I want to remove defaultvalue that dropdownlist captures when I bound the control to sqldatasource. So that user selects from list. Secondly, How to dropdown the list when it got focus. Regards Asif Rehman

    A 1 Reply Last reply
    0
    • A Asif Rehman

      I want to remove defaultvalue that dropdownlist captures when I bound the control to sqldatasource. So that user selects from list. Secondly, How to dropdown the list when it got focus. Regards Asif Rehman

      A Offline
      A Offline
      Abhijit Jana
      wrote on last edited by
      #2

      Asif Rehman wrote:

      I want to remove defaultvalue that dropdownlist captures when I bound the control to sqldatasource. So that user selects from list.

      Try this, myDropDownList.Items.RemoveAt(0)

      Asif Rehman wrote:

      Secondly, How to dropdown the list when it got focus.

      Didn't get your question :confused:

      Cheers ! Abhijit Jana | My Blog | @Twitter | Disclaimer

      A 1 Reply Last reply
      0
      • A Abhijit Jana

        Asif Rehman wrote:

        I want to remove defaultvalue that dropdownlist captures when I bound the control to sqldatasource. So that user selects from list.

        Try this, myDropDownList.Items.RemoveAt(0)

        Asif Rehman wrote:

        Secondly, How to dropdown the list when it got focus.

        Didn't get your question :confused:

        Cheers ! Abhijit Jana | My Blog | @Twitter | Disclaimer

        A Offline
        A Offline
        Asif Rehman
        wrote on last edited by
        #3

        Abhijit Jana wrote:

        Didn't get your question

        Actually I'm basically a windows developer in which on gotfocus event I can dropdown list which makes user easy to select and type. Is there any way when I dropdownlist gets focus it automatically opens(drop down). Hope you understand what I'm trying to say. Regards Asif Rehman

        A 1 Reply Last reply
        0
        • A Asif Rehman

          Abhijit Jana wrote:

          Didn't get your question

          Actually I'm basically a windows developer in which on gotfocus event I can dropdown list which makes user easy to select and type. Is there any way when I dropdownlist gets focus it automatically opens(drop down). Hope you understand what I'm trying to say. Regards Asif Rehman

          A Offline
          A Offline
          Abhijit Jana
          wrote on last edited by
          #4

          Yes, There is an similar question in Q&A section, Have a look http://www.codeproject.com/Answers/89611/ASP-NET-how-to-create-a-dropdownlist-that-onfocus-.aspx#answer2[^] Even you can see this also http://forums.asp.net/t/1118333.aspx[^] Hope this will help you !!

          Cheers ! Abhijit Jana | My Blog | @Twitter | Disclaimer

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups