Hi, Does anyone know if it possible to put a hyperlink into the footer of a datagrid? What I am doing is showing a top ten list and I then want to offer the visitors the opportunity to see the rest of the list by putting a 'more...' in the footer. Thanking
you in advance.
Here are two ways: -- ** Make one of your columns a template column and define the hyperlink in the Footertemplate for that column ** Handle ItemCreated for the grid, watch for the footer item to be created, and dynamically add the hyperlink then.
Hi Steve Try adding this code in the itemcreated method of your datagrid..
If e.Item.ItemType = ListItemType.Footer Then
Dim lnkMore As New HyperLink()
lnkMore.Text = "More..."
lnkMore.NavigateUrl = "your url"
e.Item.Controls(0).Controls.Add(lnkMore)
End If
Hope this help.
The most wasted day is that in which we have not laughed.
Stevet26
Member
285 Points
60 Posts
Hyperlink in Footer
Aug 01, 2003 02:03 PM|LINK
JimRoss [MVP...
Star
10080 Points
2008 Posts
Re: Hyperlink in Footer
Aug 01, 2003 02:10 PM|LINK
MS MVP ASP.NET [VC++/MFC emeritus]
Old Dog Learns New Tricks
Preferred programming language: cuneiform on clay tablets
new2ASPnet
Member
700 Points
140 Posts
Re: Hyperlink in Footer
Aug 01, 2003 02:55 PM|LINK
V i r g i l R e b o t o n