xor2
Programmer
- Mar 24, 2005
- 22
HI,
This is the procedure which prints my chart:
var
PrintRct : tRect;
OldPOrient : tPrinterOrientation;
begin
if printersetupdialog1.Execute then begin
OldPOrient := Printer.Orientation;
PrintRct.Top := 0;
PrintRct.Left := 0;
PrintRct.Bottom := Printer.PageWidth-1;
PrintRct.Right := Printer.PageHeight-1;
with Chart do begin
Printer.Orientation := poLandScape;
PrintRect (PrintRct);
Printer.Orientation := oldPOrient;
end;
end;
The problem is with option in setupdialog window (landscape or portrait).
When portrait is set, chart is printered in landScape (as option indicates before printrect), but when i change it to landscape chart is printered is also as landscape, but teh chart doesn;t fill whole paper, and its height is greater the paper's width ....
What is going on ??
This is the procedure which prints my chart:
var
PrintRct : tRect;
OldPOrient : tPrinterOrientation;
begin
if printersetupdialog1.Execute then begin
OldPOrient := Printer.Orientation;
PrintRct.Top := 0;
PrintRct.Left := 0;
PrintRct.Bottom := Printer.PageWidth-1;
PrintRct.Right := Printer.PageHeight-1;
with Chart do begin
Printer.Orientation := poLandScape;
PrintRect (PrintRct);
Printer.Orientation := oldPOrient;
end;
end;
The problem is with option in setupdialog window (landscape or portrait).
When portrait is set, chart is printered in landScape (as option indicates before printrect), but when i change it to landscape chart is printered is also as landscape, but teh chart doesn;t fill whole paper, and its height is greater the paper's width ....
What is going on ??