DataGrid中点击一行 [英] DataGrid clickable row

查看:188
本文介绍了DataGrid中点击一行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在寻找一种方式为我的用户点击一个排在我的DataGrid,其中,如果该点击反正他们将拿起的UniqueID列,然后打开一个新的网页,其中将被称为uniqueidview.aspx的使用的UniqueID,因为它是在一个MySQL查询主键。我可以做MySQL的部分,但我无法找到一个步行通过,或指导如何使用一个DataGrid要做到这一点,我已经找到了使用数据视图少数,任何帮助将是真棒。谢谢!

I'm looking for a way for my users to click on a row on my DataGrid where if that click anyway they would pick up the UniqueID column, and then open an new page which would be called "uniqueidview.aspx" that uses the UniqueID as it's primary key in a MySQL query. I'm able to do the MySQL part but i can't find a walk-through or guide on how to do this using a DataGrid, i've found a few using DataView, any help would be awesome. Thanks!

推荐答案

4家伙从罗拉贴出一篇文章的创建行可选DataGrid控件很多年了。在文章中,单击行将使电网进入编辑模式。

4 Guys From Rolla posted an article Creating a Row-Selectable DataGrid Control many years back. In the article, clicking on the row would put the grid into edit mode.

您可能能够使用为出发点,并修改它做你在找什么做的。

You might be able to use that as a starting point, and modify it to do what you're looking to do.

您使用的是实际的的DataGrid (从.NET 1.1),或者你的意思是的GridView (2.0 +)?

Are you using an actual DataGrid (from .NET 1.1), or do you mean the GridView (2.0+)?

如果你实际上是在谈论的GridView,这里是另一个链接:

If you're actually talking about GridView, here's another link:

制定行可点击GridView控件

这篇关于DataGrid中点击一行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆