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. How to get text From Page1 to Page2?

How to get text From Page1 to Page2?

Scheduled Pinned Locked Moved ASP.NET
csharpasp-netcomtutorial
3 Posts 3 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.
  • Z Offline
    Z Offline
    Zeeshan Ahmed Memon
    wrote on last edited by
    #1

    Dear Programmer, I am developing an application in ASP.NET using language VB.NET. I have created two pages named Page1 and Page2. On Page1 I have placed two textboxes to get input from the user and also put a button. I want that the data which I input in the textboxes placed on Page1 will be displayed on Page2. Please tell me what shall I do to accomplish my task. You can tell me on this ID: zeeshan_st2003@yahoo.com Waiting for your reply. Your Friend, Zeeshan Ahmad Memon.

    S P 2 Replies Last reply
    0
    • Z Zeeshan Ahmed Memon

      Dear Programmer, I am developing an application in ASP.NET using language VB.NET. I have created two pages named Page1 and Page2. On Page1 I have placed two textboxes to get input from the user and also put a button. I want that the data which I input in the textboxes placed on Page1 will be displayed on Page2. Please tell me what shall I do to accomplish my task. You can tell me on this ID: zeeshan_st2003@yahoo.com Waiting for your reply. Your Friend, Zeeshan Ahmad Memon.

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

      you can pass data between pages in multiple ways: 1. store the data in session and then redirect (response.redirect or server.transfer) to the next page and access the data from session. 2. you can pass data in query string 3. you can set postbackurl for the button and then access the values from the previous page using Request.Form like: in page 1 do this: <asp:Button ID="button1" Runat=server Text="submit" PostBackUrl="~/Page2.aspx" /> and then on page 2 use string field1data = Request.Form("fieldfrompage1"); `4. you can access the previous page controls using PreviousPage.Controls.. ----- `

      1 Reply Last reply
      0
      • Z Zeeshan Ahmed Memon

        Dear Programmer, I am developing an application in ASP.NET using language VB.NET. I have created two pages named Page1 and Page2. On Page1 I have placed two textboxes to get input from the user and also put a button. I want that the data which I input in the textboxes placed on Page1 will be displayed on Page2. Please tell me what shall I do to accomplish my task. You can tell me on this ID: zeeshan_st2003@yahoo.com Waiting for your reply. Your Friend, Zeeshan Ahmad Memon.

        P Offline
        P Offline
        pmarfleet
        wrote on last edited by
        #3

        In ASP.NET 2.0, you can use cross-page postbacks to accomplish this. Have a look at this article[^].

        Zeeshan Memon wrote:

        You can tell me on this ID: zeeshan_st2003@yahoo.com

        No. I answer questions on this forum for everyone's benefit, not just yours.

        Paul Marfleet "No, his mind is not for rent To any God or government" Tom Sawyer - Rush

        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