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 can I send data from one page to Another page's Gridview row.

How can I send data from one page to Another page's Gridview row.

Scheduled Pinned Locked Moved ASP.NET
comsysadmindockertutorialquestion
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.
  • R Offline
    R Offline
    rprateek
    wrote on last edited by
    #1

    I have a gridview and have following columns: <asp:TemplateField HeaderText="Test" > <ItemTemplate> <asp:TextBox ID="txtTest" runat="server" Width="200px" MaxLength="30" Text='<%# Eval("TestString") %>' /> </ItemTemplate> </asp:TemplateField> <asp:TemplateField HeaderText="Click Here" > <ItemTemplate> <asp:Button ID="cmd1" CommandName="cmd1" CommandArgument='<%# Container.DisplayIndex %>' Text="ClickHere" OnClientClick="openpage2(this);return false;" runat="server" /> </ItemTemplate> </asp:TemplateField> a textbox and a command button. OnClientClick of the command button i have opened a new page Now i need to pass the value to the clicked row textbox from the new window. Do anyone know how to acheive this

    Blog for Programmers

    A 1 Reply Last reply
    0
    • R rprateek

      I have a gridview and have following columns: <asp:TemplateField HeaderText="Test" > <ItemTemplate> <asp:TextBox ID="txtTest" runat="server" Width="200px" MaxLength="30" Text='<%# Eval("TestString") %>' /> </ItemTemplate> </asp:TemplateField> <asp:TemplateField HeaderText="Click Here" > <ItemTemplate> <asp:Button ID="cmd1" CommandName="cmd1" CommandArgument='<%# Container.DisplayIndex %>' Text="ClickHere" OnClientClick="openpage2(this);return false;" runat="server" /> </ItemTemplate> </asp:TemplateField> a textbox and a command button. OnClientClick of the command button i have opened a new page Now i need to pass the value to the clicked row textbox from the new window. Do anyone know how to acheive this

      Blog for Programmers

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

      rprateek wrote:

      OnClientClick of the command button i have opened a new page

      You can Pass The GridView Row Index or Any ID that is identical with this row and send this as Query string while opening the page. And Read the data from that same id in next page.

      cheers, Abhijit CodeProject MVP My Recent Article : Exploring Session in ASP.Net

      R 1 Reply Last reply
      0
      • A Abhijit Jana

        rprateek wrote:

        OnClientClick of the command button i have opened a new page

        You can Pass The GridView Row Index or Any ID that is identical with this row and send this as Query string while opening the page. And Read the data from that same id in next page.

        cheers, Abhijit CodeProject MVP My Recent Article : Exploring Session in ASP.Net

        R Offline
        R Offline
        rprateek
        wrote on last edited by
        #3

        thanks for the reply how would i pass row index that's what is my question

        Blog for Programmers

        A 1 Reply Last reply
        0
        • R rprateek

          thanks for the reply how would i pass row index that's what is my question

          Blog for Programmers

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

          rprateek wrote:

          how would i pass row index that's what is my question

          Read This one Get GridView selected row DataKey in Javascript[^] :)

          cheers, Abhijit CodeProject MVP My Recent Article : Exploring Session in ASP.Net

          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