We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Links not showing even when EnableHyperlinks = True

Thread ID:





100076 Jun 30,2011 08:06 PM UTC Jul 1,2011 05:25 AM UTC ASP.NET Web Forms (Classic) 1
Tags: PDF
Daniel Harmon
Asked On June 30, 2011 08:06 PM UTC

I am outputting a pdf from an html string. The only string I am passing is a link Go to page

It makes it look like a link on the outputted pdf but it is not clickable.

Here is some code:

Public Class PdfUtils
Public Sub New()

End Sub

Private Globalhtml As String
Private GLobalimage As Image

Public Sub ConvertHtmlStringToPDF(html As String, ByRef page As PdfPage)
Globalhtml = html
Dim t As Thread = New Thread(New ThreadStart(AddressOf ConvertFromString))
Dim metafile As PdfMetafile = New PdfMetafile(GLobalimage)

metafile.Quality = 100

Dim format As New PdfMetafileLayoutFormat
format.Break = PdfLayoutBreakType.FitPage
format.Layout = PdfLayoutType.Paginate
format.SplitTextLines = False

metafile.Draw(page, New PointF(0, 0), format)
End Sub

Private Sub ConvertFromString()
Dim html As New HtmlConverter
html.EnableHyperlinks = True
GLobalimage = html.FromString(Globalhtml, ImageType.Metafile, 900, -1, AspectRatio.KeepWidth)

End Sub

Suresh M [Syncfusion]
Replied On July 1, 2011 05:25 AM UTC

Hi Daniel,

Thank you for your interest on Syncfusion products.

Please use the HtmlToPdfResult.Render method to get the HTMLConverter options such as Hyperlinks, PageBreaks instead of drawing metafiles in the PdfPage. Please refer to the sample available in the link below.


Please let us know if you have any queries.

Suresh M


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon