I am using the latest version of the winforms controls (2011.1.11.419). When exporting to PDF, my code is not raising the HTMLCellFormatting event. Here is the pdf export code.
Here is the HTMLCellFormatting:
Any ideas why the the oPdfExporter_HTMLCellFormatting event is not raised?
Thanks.
Dim oPdfExporter As ExportToPDF = New ExportToPDF(Me._oSelectedGrid) oPdfExporter.FileExtension = "pdf"oPdfExporter.PageTitle = "Dealer Inventory"oPdfExporter.Scale = 0.5F oPdfExporter.PdfExportSettings.PageHeight = 210 oPdfExporter.PdfExportSettings.PageWidth = 297 oPdfExporter.ExportVisualSettings = FalseoPdfExporter.HiddenColumnOption = HiddenOption.DoNotExport oPdfExporter.HiddenRowOption = HiddenOption.DoNotExport oPdfExporter.SummariesExportOption = SummariesOption.DoNotExport oPdfExporter.FitToPageWidth = TrueoPdfExporter.PdfExportSettings.FontType = Telerik.Apoc.Render.Pdf.FontType.Embed Dim sTempPath As String = My.Computer.FileSystem.SpecialDirectories.CurrentUserApplicationData & "\Dealer_Inventory.pdf"oPdfExporter.RunExport(sTempPath) oPdfExporter = NothingHere is the HTMLCellFormatting:
Private Sub oPdfExporter_HTMLCellFormatting(ByVal sender As Object, ByVal e As Telerik.WinControls.UI.Export.HTML.HTMLCellFormattingEventArgs) If e.GridColumnIndex = 1 AndAlso e.GridRowInfoType.Equals(GetType(GridViewDataRowInfo)) Then e.HTMLCellElement.Value = "Test value" e.HTMLCellElement.Styles.Add("background-color", ColorTranslator.ToHtml(Color.Orange)) End IfEnd SubAny ideas why the the oPdfExporter_HTMLCellFormatting event is not raised?
Thanks.