Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > mailto in hyperlink field of datagrid

Thread Tools

mailto in hyperlink field of datagrid

Posts: n/a
I have seen sample code to add mailto feature in datagrid hyperlink
field using the RowDataBound event.

I did it a bit different. e-amil address are stored in a database. Removed).

I created a derived field in my select statement select 'mailto:' +
[EMAIL]. from table. I converted the hyplerlink to a template field. I
then edited the source as follows.

<asp:HyperLink ID="HyperLink1" runat="server"
NavigateUrl='<%#Bind("mailto") %>' Text="E-Mail"></asp:HyperLink>

This is working for me.

Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
What to do with #<URI::MailTo:0xb762601c> Thomas Gagne Ruby 2 03-15-2013 10:49 AM
MailTo Hyperlink in Gridview Stuart Ferguson ASP .Net 7 08-27-2009 07:36 AM
mailto: in datagrid hyperlink =?Utf-8?B?c2Ft?= ASP .Net 3 12-30-2005 04:02 PM
Gridview hyperlink column mailto event =?Utf-8?B?TWFyY2lhbA==?= ASP .Net 2 12-29-2004 11:45 PM
mailto on hyperlink control Rod Snyder ASP .Net 2 08-19-2004 10:57 AM