Difference between Hyperlink and HyperLinkField
what is the difference between Hyperlink and HyperLinkField?
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Priya LingePosted Jul 28, 2011, 12:48 AM
1. HyperlinkField is a column type for data bound controls such as GridView. It will display a link for each
record in the data bound control.
width=90% cellpadding=5 font-size="8pt"
autogeneratecolumns=false
headerstyle-backcolor="maroon"
headerstyle-forecolor="khaki"
headerstyle-font-bold
rowstyle-verticalalign="top">
<columns>
datafield="id" />
datafield="Name" />
datafield="fee"
<asp:hyperlinkfieldheadertext="Title"
datatextfield="title"
datanavigateurlformatstring="page_details.aspx?id={0}"
datanavigateurlfields="id" />
htmlencode=false
dataformatstring="{0:n2}"
itemstyle-horizontalalign="right" />
columns>
asp:gridview>
2.Hyperlink would have to be declared inside an ItemTemplate in a GridView as it does not inherit from DataControlField.Hope this will help you.
Thanks.