Solved

jquery .NET Get column value from selected row in gridview.

Posted on 2012-04-11
1
567 Views
Last Modified: 2012-04-27
I would like to retreive the value in the second column of a gridview (LogViewsGV) and then
display that value to a label on the screen.  This is only intended to get me going for more
complex data retrieval for my development.  Here's what I have thus far, but just can't seem
to get a working syntax.  Currently the default value "000" is being returned.

$("#<%=LogViewsGV.ClientID %> tr").click(function () { OrderResNum = $("#<%=LogViewsGV.ClientID %> tr:selected").find("td:eq(1)").text() })
GetValue.jpg
0
Comment
Question by:dparkes
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 82

Accepted Solution

by:
leakim971 earned 500 total points
ID: 37837228
try this :

$("tr", "#<%=LogViewsGV.ClientID %>").click(function () { OrderResNum = $("td:eq(1)", this).text(); });

Open in new window

0

Featured Post

SharePoint Admin?

Enable Your Employees To Focus On The Core With Intuitive Onscreen Guidance That is With You At The Moment of Need.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

ADCs have gained traction within the last decade, largely due to increased demand for legacy load balancing appliances to handle more advanced application delivery requirements and improve application performance.
I had an issue with InstallShield not being able to use Computer Browser service on Windows Server 2012. Here is the solution I found.
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…
Suggested Courses
Course of the Month7 days, 6 hours left to enroll

623 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question