Groups | Blog | Home
all groups > asp.net datagrid control > october 2003 >

asp.net datagrid control : Mouse over in datagrid?


Peter Kamitz
10/7/2003 7:32:59 PM
I want to show a message when the mouse is over a tablerow of the datagrid!
Any ideas how to make such a thing??


thanks peter

Saravana [MVP]
10/8/2003 10:38:08 AM
You can go for tooltip property of datagriditem. If you set tooltip for your
datagriditem, then it will show message(tooltip) when mouse moves over
tablerow of the datagrid. For setting tooltip for datagriditem, see this
sample.


Private Sub DataGrid1_ItemCreated(ByVal sender As Object, ByVal e As
System.Web.UI.WebControls.DataGridItemEventArgs)
Handles DataGrid1.ItemCreated

If e.Item.ItemType = ListItemType.item or e.Item.ItemType =
ListItemType.alternatingitem Then
e.item.Tooltip = "Your Tooltip...."

end if

End Sub



--
Saravana
Microsoft MVP - ASP.NET
www.extremeexperts.com



[quoted text, click to view]

AddThis Social Bookmark Button