I wish there was a ToolTip field in HyperLinkField as there is one in HyperLink.
I’m creating a HyperLinkField by code before binding to my data source:
HyperLinkField hl = new HyperLinkField();
hl.DataNavigateUrlFields = new string[] { "col" };
hl.DataNavigateUrlFormatString = "{0}";
hl.DataTextField = "Foo";
Is there any way to also set a value to something which will render as a tooltip (or alt text)?
Any help will be appreciated.
That’s correct, there’s no tooltip/alt text property in a HyperlinkField. To get around this shortcoming, you need to use a template field and add a regular Hyperlink control.
However, doing this in a programmatic requires a lot of work. You need to create your own class that implements the ITemplate interface. Here’s a tutorial on that.