473,322 Members | 1,540 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,322 software developers and data experts.

How to pass value from gridview to another webform?

2
I am having two webforms,one is having gridview which have 3 columns namely SlotId,SlotName,SetSlot.The last column is having button ,when I clicked that button second webform opens.When second form opens I want to show SlotName from the selected row of gridview in the second webform.How to show this?
Nov 7 '12 #1
3 2710
Frinavale
9,735 Expert Mod 8TB
Handle the click event for the button in the GridView.

Retrieve the button that was clicked from the sender parameter of the method that handles the click event.

Once you have the button, you can use it's NamingContainer Property to retrieve the row that the button belongs to.

From the row, you can retrieve the data that it is bound to.

Store the object in session, or in cookies or however you want to so that you can pass this information to the next page.

-Frinny
Nov 8 '12 #2
kanak
2
can u please explain me this in detail because I am first time doing this.Waiting for reply...........Thank you in advance
Nov 17 '12 #3
zmbd
5,501 Expert Mod 4TB
Kanak,
You would benifit more from our help if you will make an effort to do this yourself first. Please make your best effort using the information that Frinavale has provided. If you are still having issues, then post back your code (ofcourse, formatted using the <CODE/> button) along with any specific error numbers/messages you receive and a clear explanation of what the problem is versus what you have as a goal.
Nov 17 '12 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Tor Inge Rislaa | last post by:
How to refer to a variable on another webform Hi, I have a Webform1 with a public variable that is assigned a value before my Webform2 is displayed. In the Page_Load procedure of Webform2 I want...
3
by: Dean Slindee | last post by:
Would like to call the TabShow function on WebForm InOutHost from another WebForm in same project, but cannot figure out how to get a reference. Can this be done? In this statement: Call...
17
by: Rabbit | last post by:
Hi, On my 1st page, i have a function which gets a new ID value and need to transfer to another immediately. which I want to get in 2nd page using Request.form("txtID"), but doesn't work, the...
1
by: msuk | last post by:
All, I have a webform e.g. a.aspx that contains an a table of 2 cols 1 row. In col1 I have an IFRAME and in col2 I have some labels/text boxes. Now the IFRAME source is say 'b.aspx' that...
2
by: Luqman | last post by:
How can I open another WebForm in ASP.Net / VS 2005 without closing the Current Webform. I tried using Server.Transfer("Form2.Aspx",True) on Button_Click of Form1 but it close the current web...
1
by: almurph | last post by:
Hi everyone, I have an APS.NET (v1.1) type button on a webform page. What I want it to do is when the user clicks it, it then calls another webform page that appears in a pop-up window. Now I...
0
by: dan | last post by:
Hi, I have a GridView with five columns. One of the column renders its content either as a FileUpload or TextBox - depending on a value in another cell. I created an EditItemTemplate for the...
5
by: =?Utf-8?B?UGF1bA==?= | last post by:
Hi I have start web form and when the user clicks a button (server.transfer) they are directed to the second webform. I was wondering if there is a way to create an instance of the first webform...
2
by: yanapul | last post by:
in webform 1, i have search button when i click its open webform2 and there the gridview. I want when i click the link in gridview in webform 2 then it close webform 2 and change the datasource...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.