Ver Mensaje Individual
  #8  
Antiguo 14-05-2007
carlohg carlohg is offline
Registrado
 
Registrado: may 2007
Ubicación: Medellin - Colombia
Posts: 9
Reputación: 0
carlohg Va por buen camino
Realmente quiero hacer ese mdi child para configurar las margenes de un Richedit para imprimir

Alguna otra Sugerencia?

Código Delphi [-]
if PrintDialog1.Execute then
  begin
    PixelsX := GetDeviceCaps(Printer.Handle, LOGPIXELSX);
    PixelsY := GetDeviceCaps(Printer.Handle, LOGPIXELSY);
    LeftSpace := GetDeviceCaps(Printer.Handle, PHYSICALOFFSETX);
    TopSpace := GetDeviceCaps(Printer.Handle, PHYSICALOFFSETY);
    
   {en este lugar incluiria los valores desde mi formchild}

    R.Left := Round(PixelsX * valor desde MDICHILD) - LeftSpace;
    R.Right := Round(PixelsX * valor desde MDICHILD) - LeftSpace;
    R.Top := Round(PixelsY * valor desde MDICHILD) - TopSpace;
    R.Bottom := Round(PixelsY * valor desde MDICHILD) - TopSpace;
 
{/////}

    RichEdit1.PageRect := R;
    RichEdit1.Lines.Add('');
    RichEdit1.Lines.Add(DateTimeToStr(Now));
    RichEdit1.Print('Reporte'+Edit1.Text);
  end;
Responder Con Cita