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. Retrive Asp:DropDownList Addes Items [modified]

Retrive Asp:DropDownList Addes Items [modified]

Scheduled Pinned Locked Moved ASP.NET
csharpjavaasp-netdata-structurestools
1 Posts 1 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.
  • S Offline
    S Offline
    sivaprakas
    wrote on last edited by
    #1

    Hi, I develop a project in ASp.net in my project i use java script function to add textbox value to Dropdownlist when i click ASp.Butoon the Dropdownlist values age disappeared i can't get dropdownlist values how can i get pls help me sn-asp:TextBox list-asp:DropDownList function Button8_onclick() { var t alert("Hai"); //alert(document.form1.elements["dl"].value); //alert(document.getElementById("sn2").value);if(document.getElementById("sn").value!="") { if(document.getElementById("list").value=="1") { t = document.getElementById("sn").value st = new Option(t,t)document.getElementById("snum1").add(st); } if(document.getElementById("list").value=="2") { t = document.getElementById("sn").value st = new Option(t,t) document.getElementById("snum2").add(st); } if(document.getElementById("list").value=="3") { t = document.getElementById("sn").value st = new Option(t,t) document.getElementById("snum3").add(st); } if(document.getElementById("list").value=="4") { t = document.getElementById("sn").value st = new Option(t,t) document.getElementById("snum4").add(st); } if(document.getElementById("list").value=="5") { t = document.getElementById("sn").value st = new Option(t,t) document.getElementById("snum5").add(st); } if(document.getElementById("list").value=="6") { t = document.getElementById("sn").value st = new Option(t,t) document.getElementById("snum6").add(st); } if(document.getElementById("list").value=="7") { t = document.getElementById("sn").value st = new Option(t,t) document.getElementById("snum7").add(st); } if(document.getElementById("list").value=="8") { t = document.getElementById("sn").value st = new Option(t,t) document.getElementById("snum8").add(st); } if(document.getElementById("list").value=="9") { t = document.getElementById("sn").value st = new Option(t,t) document.getElementById("snum9").add(st); } if(document.getElementById("list").value=="10") { t = document.getElementById("sn").value st = new Option(t,t) document.getElementById("snum10").add(st); } } code Window protected void Button10_Click(object sender, EventArgs e) { for (int j = 0; j < snum10.Items.Count; j++) { //tListt.Items.Add(snListt.Items[j].ToString()); snd[10] = snd[10] + "/" + snum10.Items[j].ToString(); } } snd[] string Array snum1 DropDownlist

    mo

    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