Hello,
I have a problem exporting to PDF a MindFusion.Diagramming.Diagram flowchart.
The grid lanes are not being shown. I use the follwing code to force the gridpen to be set, but with the pdf exporter does not create the grid lane.
I also create a wmf image for the same flowchart using the Mindfusion WmfExporter, and this work fine.
I don't know the reason why it is shown on the wmf image but not in the final pdf exported. I also read in an old post something like the cells has not to be wiht empty strings, but it didn't work.
Thanks.
var pdfExporter = new PdfExporter
{
AutoScale = PdfExportOptions.Instance.PdfAutoScale,
InvisibleItems = PdfExportOptions.Instance.InvisibleItems,
Margins = PdfExportOptions.Instance.Margins,
PageOrientation = PdfExportOptions.Instance.PageOrientation,
PageSize = PdfExportOptions.Instance.PageSize,
Scale = PdfExportOptions.Instance.PdfScale,
};
MindFusion.Drawing.Pen gridlinePenPDF =
new MindFusion.Drawing.Pen(
new MindFusion.Drawing.HatchBrush(HatchStyle.Percent50, Color.Gray, Color.Transparent), 0);
for (int i = 0; i < flowChart.LaneGrid.RowCount; i++)
{
for (int j = 0; j < flowChart.LaneGrid.ColumnCount; j++)
{
flowChart.LaneGrid[j, i].Style.LeftBorderPen =
flowChart.LaneGrid[j, i].Style.TopBorderPen = gridlinePenPDF;
}
}
pdfExporter.Export(FlowChart, fileName);