T
Toby Riley
Any ideas on how i would select a row from a datagrid using a mouse click
event on the row. I need to set the selectedindex. I using the following
code to create a rollover as the mouse moves through the rows. All I need is
the bit to make the onclick event work.
Private Sub dgUserList_ItemDataBound(ByVal sender As Object, ByVal e As
System.Web.UI.WebControls.DataGridItemEventArgs) Handles
dgUserList.ItemDataBound
If e.Item.ItemType = ListItemType.Item Or e.Item.ItemType =
ListItemType.AlternatingItem Then
e.Item.Attributes.Add("onmouseover",
"this.style.backgroundColor='Silver'")
e.Item.Attributes.Add("onmouseout",
"this.style.backgroundColor='white'")
End If
End Sub
Thanks in advance
Toby
event on the row. I need to set the selectedindex. I using the following
code to create a rollover as the mouse moves through the rows. All I need is
the bit to make the onclick event work.
Private Sub dgUserList_ItemDataBound(ByVal sender As Object, ByVal e As
System.Web.UI.WebControls.DataGridItemEventArgs) Handles
dgUserList.ItemDataBound
If e.Item.ItemType = ListItemType.Item Or e.Item.ItemType =
ListItemType.AlternatingItem Then
e.Item.Attributes.Add("onmouseover",
"this.style.backgroundColor='Silver'")
e.Item.Attributes.Add("onmouseout",
"this.style.backgroundColor='white'")
End If
End Sub
Thanks in advance
Toby