This is a migrated thread and some comments may be shown as answers.

Email link format mailto:{0} doesnt work in the radgridview

4 Answers 79 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Jose R
Top achievements
Rank 1
Jose R asked on 01 Sep 2011, 04:09 AM
I have a small question. I'm trying to display the user email addressin a datagrid for winform and i have tried everything to  make it look like a link and it doesnt work.  All I want is the user to be able to click the email address to be able to sendan email to the selected address.  
Can anyone help me out here by letting meknow whats the format to use?    Remember I'm looking for the Radgridview for Winforms not the ASP.net one..


Thanks in advance


Jose 

4 Answers, 1 is accepted

Sort by
0
Jason Parrish
Top achievements
Rank 1
answered on 01 Sep 2011, 04:29 PM
Try this...I just wrote this code a few minutes ago for my project.

If TypeOf e.CellElement.ColumnInfo Is GridViewTextBoxColumn AndAlso Not _
           (TypeOf e.CellElement.RowElement Is GridTableHeaderRowElement) AndAlso _
               e.Column.Name.ToUpper = "UPDATEDBY" Then
 
           e.CellElement.DisableHTMLRendering = False
           e.CellElement.Text = "<html><a href=""mailto:" & e.Row.DataBoundItem("emailaddress") & """>" & e.Row.DataBoundItem("updatedby") & "</a></html>"
 
 
End If
0
Jose R
Top achievements
Rank 1
answered on 02 Sep 2011, 06:24 AM
i tried that but it still doesnt work.
My datagrid is form Winforms and it contains child templates and is batabound to a relation.

any other suggestions?
thanks in advance

Jose
0
Jack
Telerik team
answered on 02 Sep 2011, 02:06 PM
Hello Jose R,

There is no built-in hyperlink column in RadGridView. We plan to add this feature in one of our upcoming releases. However, the following code library article demonstrates how to create one. I hope it helps.

Should you have any further questions, do not hesitate to ask.
 
All the best,
Jack
the Telerik team

Thank you for being the most amazing .NET community! Your unfailing support is what helps us charge forward! We'd appreciate your vote for Telerik in this year's DevProConnections Awards. We are competing in mind-blowing 20 categories and every vote counts! VOTE for Telerik NOW >>

0
Jose R
Top achievements
Rank 1
answered on 02 Sep 2011, 05:11 PM
AWESOME 
This one work for me. very nice job. 
Thanks a lot for the help.

Blessings

Jose
Tags
GridView
Asked by
Jose R
Top achievements
Rank 1
Answers by
Jason Parrish
Top achievements
Rank 1
Jose R
Top achievements
Rank 1
Jack
Telerik team
Share this question
or