![]() |
![]() |
| Paypal | FTP | CCD | Buscar | Trucos | Trabajo | Foros |
|
#2
|
|||
|
|||
|
la solucion seria algo asi:
with pdf do begin FileName := nomArch; // starting printing document. BeginDoc; sp.ParamByName('@id_cuenta').AsInteger := idCuenta; sp.ParamByName('@desde').AsDate := desde; sp.ParamByName('@hasta').AsDate := hasta; sp.Open; cantpag := sp.RecordCount div PRGridPanel1.RowCount; if (sp.RecordCount mod PRGridPanel1.RowCount)>0 then inc(cantpag); pag := 1; while not sp.Eof do Print(PRPage1); // save document. EndDoc; sp.Close; end; finally Screen.Cursor := crDefault; end; procedure TfmStatement.PRGridPanel1AfterPrint(Sender: TObject; ACanvas: TPRCanvas; Rect: TRect); begin inc(pag); end; procedure TfmStatement.PRLayoutPanel1BeforePrint(Sender: TObject; ACanvas: TPRCanvas; Rect: TRect); begin laPag.Caption := 'Page '+IntToStr(pag)+' of '+IntToStr(cantpag); end;
__________________
Marín Ignacio Borthiry (Viet) - "El hombre arriesga su vida cada vez que elije y eso es lo que lo hace libre" ;) |
| Herramientas | Buscar en Tema |
| Desplegado | |
|
|
|