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. querystring

querystring

Scheduled Pinned Locked Moved ASP.NET
databasetutorialquestion
2 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.
  • U Offline
    U Offline
    UD IA
    wrote on last edited by
    #1

    hi, how to use querystring. how to set and get query string. :-D

    I will do my best? Integrated Solutions, Bikaner (Raj.), India

    S 1 Reply Last reply
    0
    • U UD IA

      hi, how to use querystring. how to set and get query string. :-D

      I will do my best? Integrated Solutions, Bikaner (Raj.), India

      S Offline
      S Offline
      snouto
      wrote on last edited by
      #2

      hello... you can set a query string by padding it to the url you want your user to be redirected to for example at page 1 ========= void button1_click (object sender , EventArgs e) { Response.Redirect("page2.aspx?username="+textbox1.text+"&password="+textbox2.text); } now at page2 =========== you can access those query string data by accessing the query string request at the page2 as follows at page 2 ======== void Page_Load(object sender , EventArgs e) { if(Request.QueryString["username"] != null && Request.QueryString["password"] != null) { //do something with those querystring values string username = Request.QueryString["usename"]; string password = Request.QueryString["password"]; } }

      Human knowledge belongs to the world.

      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