Esta informacin debera ser suficiente (siempre que el sistema de impresin no tenga bloqueado (uso exclusivo) el puerto virtual serie). Abrir, escribir, cerrar.
por ahora voy a seguir con el mtodo del informe porque lo del puerto es otra historia con los usb… y si el programa corre en linux o mac… ya entraramos en problemas.
Lo que no localizo es como hacer para que imprima en la impresora predeterminada y que no salga el dialogo de impresoras.
In windows write directly to port for use Escape command;
Connect your printer with driver and share this
When have the device ( sharing name ) use \\pcname\printername
Just copy a text file with data on \\pcname\printername
On MacOS/Linux find the device name on cups and just copy text file on device /dev/devicename
Other system for find the device name, use lsusb commad at prompt.
with this system ( i use this for toshiba label printer ) u can use only escape codes text, and not graphics printing.
Max.
try
mProject.Open()
catch e as VException
dim errNumber as Integer = e.ErrorNumber
dim errString as String = e.Message
MsgBox errString
end
if mProject <> nil then
vCounts = mProject.ReportCount()
end if
try
mReport = mProject.MakeNewReport(“Close_Store_Qty”, RepStrConn, SqlStr01 )
mReport.SetParameterValue(“param1”,Str(ActiveCajaReg))
catch e as VException
dim errNumber as Integer = e.ErrorNumber
dim errString as String = e.Message
MsgBox errString
end
Try
mReport.PrintToLocalPrinter(CashDrawar(1), “paper=PosPrinter” )
catch e as VException
dim errNumber as Integer = e.ErrorNumber
dim errString as String = e.Message
MsgBox " Report Print PDF " + errString
end