Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

Troubleshooting
Research
Professional Opinions
Ask a Question
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE

troubleshooting Question

ASP.NET Gridview: embedding a texbox and button in each row, passing info from that row to a function?

Avatar of kennethfine
kennethfine asked on
C#ASP.NETWeb Applications
2 Comments1 Solution1364 ViewsLast Modified:
I'm making an administrative interface that lists records in a GridView.

For *each* row in the gridview, I would there to be two interface elements in addition to some information associated with the record. Those interface elements are a Button and a TextBox. The idea is that the administrator using the interface will fill in an e-mail address and press the button if they want to send that particular record to someone by e-mail.  (I know how to manage all of the e-mailing stuff.)

I know how to do a variation of this using a commandname on a simple link in a repeater, but I have never done this with a textbox.

I've made many interfaces similar to what's described above using Classic ASP.

How would I do this in a GridView? I imagine I'd build it using an ItemTemplate. But I'm fuzzy on how to make the UI elements repeatable, how to determine which row has been invoked, and how to grab the necessary information out of the dynamically rendered/named UI elements or otherwise pass the necessary info to the function I build to invoke the e-mailing functionality.

Thanks,
-KF
ASKER CERTIFIED SOLUTION
Avatar of DarkoLord
DarkoLordFlag of Slovenia image

Our community of experts have been thoroughly vetted for their expertise and industry experience.

Commented:
This problem has been solved!
Unlock 1 Answer and 2 Comments.
See Answers