My code uses following to convert HTML to PDF.
-----------------------------------------------------------------------------------------------------
'Dim pdf As Aspose.Pdf.Pdf = New Aspose.Pdf.Pdf
'Dim section As Aspose.Pdf.Section = pdf.Sections.Add()
Dim pdf As Aspose.Pdf.Generator.Pdf = New Aspose.Pdf.Generator.Pdf
Dim section As Aspose.Pdf.Generator.Section = pdf.Sections.Add()
section.IsLandscape = False
Dim r As StreamReader = File.OpenText(Server.MapPath(".") & "\Test.html")
section.PageInfo.PageWidth = 560
section.PageInfo.PageHeight = 1060
section.PageInfo.Margin.Top = 10
section.PageInfo.Margin.Bottom = 10
section.PageInfo.Margin.Right = 10
section.PageInfo.Margin.Left = 10
'Dim text1 As Aspose.Pdf.Text = New Aspose.Pdf.Text(section, r.ReadToEnd())
Dim text1 As Aspose.Pdf.Generator.Text = New Aspose.Pdf.Generator.Text(section, r.ReadToEnd())
r.Close()
text1.IsHtmlTagSupported = True
pdf.HtmlInfo.ImgUrl = Server.MapPath(".") & "\html\"
section.Paragraphs.Add(text1)
'pdf.Save("Test.pdf", Aspose.Pdf.SaveType.OpenInAcrobat, Response)
pdf.Save(Server.MapPath(".") & "\Report_.pdf")
---------------------------------------------------------------------------------------
Note that my licence only activates up to 7.0.0.0 so I am converting application to Aspose.Pdf 7.0.0.0.
Basically I had to convert The Aspose.Pdf.Pdf class notation to Aspose.Pdf.Generator.Pdf notation. (See commented out code above.) But now the HTML table structure conversion that worked perfectly in 5.3.0.0 now works pretty bad. Most of the table attributes for formatting and background color and whatever else are not supported. It's like the functionality took a backward step when you went from the 5.3.0.0 to 7.0.0.0 . I understand there were some major class structure changes when coming out with new versions but what are my options for getting this to work? I have to upgrade to 7.0.0.0 for the Aspose.Pdf.Facades PDF form support. Can I have two different versions of Aspose.PDf on the web server at same time?
Thanks.
M.J.N.