Sobre IsPrinter

Post Reply
User avatar
Willi Quintana
Posts: 859
Joined: Sun Oct 09, 2005 10:41 pm
Location: Cusco - Perú
Contact:

Sobre IsPrinter

Post by Willi Quintana »

Hola amigos,
Encontre esto escrito para Dephi, se podra convertir a Harbour??
Salu2


function IsPrinter : Boolean;
Const
PrnStInt : Byte = $17;
StRq : Byte = $02;
PrnNum : Word = 0; { 0 para LPT1, 1 para LPT2, etc. }
Var
nResult : byte;
Begin (* IsPrinter*)
Asm
mov ah,StRq;
mov dx,PrnNum;
Int $17;
mov nResult,ah;
end;
IsPrinter := (nResult and $80) = $80;
End;
User avatar
Antonio Linares
Site Admin
Posts: 37481
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Contact:

Post by Antonio Linares »

Willi,

> Int $17;

Ese código es para 16 bits, no para 32 bits

De todas formas, Harbour/xHarbour proporcionan IsPrinter()
regards, saludos

Antonio Linares
www.fivetechsoft.com
Post Reply