no grid lines when printing
Posted: Wed Feb 07, 2007 4:57 am
Hello,
I've got a problem where whenever I print a chart I don't get any grid lines. They're visible in the TChartPreviewer window, but they don't appear on the printout.
I've tried changing the settings of the TChartPreviewer component - if I set cpoAsBitmap to true, then I do get grid lines...but the text looks shocking, it's extremely small and blocky. Changing the PrintResolution doesn't have any effect. I've also tried changing the grid settings before executing the TChartPreviewer like this:
TrendChart->BottomAxis->Grid->Color = clBlack;
TrendChart->LeftAxis->Grid->Color = clBlack;
TrendChart->BottomAxis->Grid->Style = psSolid;
TrendChart->LeftAxis->Grid->Style = psSolid;
TrendChart->BottomAxis->Grid->Width = 2;
TrendChart->LeftAxis->Grid->Style = 2;
TrendChart->BottomAxis->Grid->Mode = pmBlack;
TrendChart->LeftAxis->Grid->Mode = pmBlack;
ChartPreview->Execute();
and then setting the values back to their original values after the trend is printed. I thought it may have been a problem with dotted lines or a non-black colour being printed, but those changes don't make any difference.
I just can't understand why the grid lines are visible in the preview but don't make it to the printer. Can anyone explain why this is happening or tell me what I need to change in order to fix it?
Thanks
Andrew
I've got a problem where whenever I print a chart I don't get any grid lines. They're visible in the TChartPreviewer window, but they don't appear on the printout.
I've tried changing the settings of the TChartPreviewer component - if I set cpoAsBitmap to true, then I do get grid lines...but the text looks shocking, it's extremely small and blocky. Changing the PrintResolution doesn't have any effect. I've also tried changing the grid settings before executing the TChartPreviewer like this:
TrendChart->BottomAxis->Grid->Color = clBlack;
TrendChart->LeftAxis->Grid->Color = clBlack;
TrendChart->BottomAxis->Grid->Style = psSolid;
TrendChart->LeftAxis->Grid->Style = psSolid;
TrendChart->BottomAxis->Grid->Width = 2;
TrendChart->LeftAxis->Grid->Style = 2;
TrendChart->BottomAxis->Grid->Mode = pmBlack;
TrendChart->LeftAxis->Grid->Mode = pmBlack;
ChartPreview->Execute();
and then setting the values back to their original values after the trend is printed. I thought it may have been a problem with dotted lines or a non-black colour being printed, but those changes don't make any difference.
I just can't understand why the grid lines are visible in the preview but don't make it to the printer. Can anyone explain why this is happening or tell me what I need to change in order to fix it?
Thanks
Andrew