Impressão de Arquivos

Delphi

31/05/2004

Oi,

Como posso acessar as propriedades de uma impressora?
Por exemplo: Se está ligada; se já imprimiu; se existe, etc.

Obrigada pela atenção!!


Fatima

Fatima

Curtidas 0

Respostas

Neudimar1

Neudimar1

31/05/2004

Function TJPrincipal.PrinterOnLine : boolean;
Const
PrnStInt : Byte = $17;
StRq : Byte = $02;
PrnNum : Word = 0; {0 Para Lpt1, 1 para lpt2, etc}
Var
nResult : Byte;
Begin
Asm
Mov ah,Strq;
Mov dx,PrnNum;
Int $17;
Mov nResult,ah;
end;
PrinterOnLine := nResult and $80 = $80;
end;


GOSTEI 0
POSTAR