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

exportToPDF View XHTML

1 Answer 43 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Phillip
Top achievements
Rank 1
Phillip asked on 06 Dec 2011, 07:07 PM
Is there a way that I can view the XHTML that is generated and used for the exportToPdf?  This will help me get the page to look the way I want it to.  Thanks

1 Answer, 1 is accepted

Sort by
0
Phillip
Top achievements
Rank 1
answered on 06 Dec 2011, 07:32 PM
Protected Sub RadGrid1_PdfExporting(ByVal sender As Object, ByVal e As Telerik.Web.UI.GridPdfExportingArgs) Handles RadGrid1.PdfExporting
    Dim FILE_NAME As String = "c:\file.txt"
    If System.IO.File.Exists(FILE_NAME) = True Then
        Dim objWriter As New System.IO.StreamWriter(FILE_NAME)
        objWriter.Write(e.RawHTML)
        objWriter.Close()
    End If
End Sub

This writes the xhtml to c:\file.txt  make sure its writable.  Still open to any suggestions for an easier way to view it.  Thanks
Tags
Grid
Asked by
Phillip
Top achievements
Rank 1
Answers by
Phillip
Top achievements
Rank 1
Share this question
or