IMPRIMIR IMAGEM ARGOX PPLA

JAILDOCC 09/08/2010 16:13:12
#349833
Bom dia amigos, estou com um problema não consigo imprimir uma imagem na impressora argox, tem um post aqui no forum com um exemplo, mas não consegui fazer funcionar, alguem tem um código fonte com essa função funcionando??? agradeço a atenção
GERARDA 10/08/2010 09:53:07
#349869
ve se te ajuda

Eis o código para impressão direto pela porta paralela

Open [Ô]lpt1[Ô] For Output As #1

Open [Ô]CaminhoImg.bmp[Ô] For Binary As #2
img = Space(LOF(2))
Get #2, 1, img
Close #2

Print #1, Chr(2) + [Ô]IABNomeImg[Ô]
Print #1, img

Print #1, Chr(2) + [Ô]m[Ô]
Print #1, Chr(2) + [Ô]KI7[Ô] + Chr(1)
Print #1, Chr(2) + [Ô]M0100[Ô]
Print #1, Chr(2) + [Ô]e[Ô]
Print #1, Chr(2) + [Ô]L[Ô]
Print #1, [Ô]D11[Ô]

Print #1, [Ô]1Y1100003000020[Ô] + [Ô]NomeImg[Ô]
Print #1, [Ô]120000003600050[Ô] & texto
Print #1, [Ô]1A0013000020280[Ô] & barra

Print #1, [Ô]Q[Ô] [Ô]0005[Ô])
Print #1, [Ô]E[Ô]
Print #1, Chr(2) + [Ô]Q[Ô]
Close #1

JAILDOCC 10/08/2010 10:12:43
#349873
Amigo GERARDA, obrigado pela resposta, eu ja tinha tentado esse código mas não funcionou na linha onde tenta gerar o binary da imagem o GET da o erro 458 - Variable uses an Automation Type not supported in Visual Basic, tentei gerar o binario da imagem de outra maneira, gerou normal , mas quando manda imprimir a imagem não sai... tem alguma outra dica q possa me ajudar? agradeço.
GERARDA 10/08/2010 13:13:15
#349885
qual seria o modelo de sua impressora
JAILDOCC 10/08/2010 15:05:52
#349904
Amigo GERARDA minha impressora é ARGOX OS-214 plus
GERARDA 11/08/2010 12:38:55
#349980
Ele utiliza uma dll da impressora Winppla.dll para imprimir.


Private Declare Function A_CreatePrn Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal selection As Integer, ByVal filename As String) As Integer
Private Declare Sub A_ClosePrn Lib [Ô]\PPLA\WINPPLA.DLL[Ô] ()
Private Declare Function A_Print_Out Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal width As Integer, ByVal height As Integer, ByVal copies As Integer, ByVal amount As Integer) As Integer
Private Declare Function A_Bar2d_Maxi Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal x As Long, ByVal y As Long, ByVal primary As Long, ByVal secondary As Long, ByVal country As Long, ByVal service As Long, ByVal mode As Byte, ByVal numeric As Long, ByVal data As String) As Long
Private Declare Function A_Bar2d_Maxi_Ori Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal x As Long, ByVal y As Long, ByVal ori As Long, ByVal primary As Long, ByVal secondary As Long, ByVal country As Long, ByVal service As Long, ByVal mode As Byte, ByVal numeric As Long, ByVal data As String) As Long
Private Declare Function A_Bar2d_PDF417 Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal x As Long, ByVal y As Long, ByVal narrow As Long, ByVal width As Long, ByVal normal As Byte, ByVal security As Long, ByVal aspect As Long, ByVal row As Long, ByVal column As Long, ByVal mode As Byte, ByVal numeric As Long, ByVal data As String) As Long
Private Declare Function A_Bar2d_PDF417_Ori Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal x As Long, ByVal y As Long, ByVal ori As Long, ByVal narrow As Long, ByVal width As Long, ByVal normal As Byte, ByVal security As Long, ByVal aspect As Long, ByVal row As Long, ByVal column As Long, ByVal mode As Byte, ByVal numeric As Long, ByVal data As String) As Long
Private Declare Function A_Bar2d_DataMatrix Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal x As Integer, ByVal y As Integer, ByVal rotation As Integer, ByVal hor_mul As Integer, ByVal ver_mul As Integer, ByVal ECC As Integer, ByVal data_format As Integer, ByVal num_rows As Integer, ByVal num_col As Integer, ByVal mode As Byte, ByVal numeric As Integer, ByVal data As String) As Long
Private Declare Function A_Prn_Barcode Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal x As Long, ByVal y As Long, ByVal ori As Long, ByVal typee As Byte, ByVal narrow As Long, ByVal width As Long, ByVal height As Long, ByVal mode As Byte, ByVal numeric As Long, ByVal data As String) As Long
Private Declare Function A_Prn_Text Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal x As Integer, ByVal y As Integer, ByVal ori As Integer, ByVal font As Integer, ByVal typee As Integer, ByVal hor_factor As Integer, ByVal ver_factor As Integer, ByVal mode As Char, ByVal numeric As Integer, ByVal data As String) As Integer
Private Declare Function A_Open_ChineseFont Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal path As String) As Long
Private Declare Function A_Prn_Text_Chinese Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal x As Long, ByVal y As Long, ByVal fonttype As Long, ByVal id_name As String, ByVal data As String, ByVal mem_mode As Long) As Long
Private Declare Function A_Prn_Text_TrueType Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal x As Integer, ByVal y As Integer, ByVal FSize As Integer, ByVal FType As String, ByVal Fspin As Integer, ByVal FWeight As Integer, ByVal FItalic As Integer, ByVal FUnline As Integer, ByVal FStrikeOut As Integer, ByVal id_name As String, ByVal data As String, ByVal mem_mode As Integer) As Long
Private Declare Function A_Prn_Text_TrueType_W Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal x As Integer, ByVal y As Integer, ByVal FHeight As Integer, ByVal FWidth As Integer, ByVal FType As String, ByVal Fspin As Integer, ByVal FWeight As Integer, ByVal FItalic As Integer, ByVal FUnline As Integer, ByVal FStrikeOut As Integer, ByVal id_name As String, ByVal data As String, ByVal mem_mode As Integer) As Long
Private Declare Function A_Draw_Box Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal mode As Byte, ByVal x As Long, ByVal y As Long, ByVal width As Long, ByVal height As Long, ByVal top As Long, ByVal side As Long) As Long
Private Declare Function A_Draw_Line Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal mode As Integer, ByVal x As Integer, ByVal y As Integer, ByVal width As Integer, ByVal height As Integer) As Integer
Private Declare Function A_Get_Graphic Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal x As Long, ByVal y As Long, ByVal mem_mode As Long, ByVal format As Byte, ByVal filename As String) As Long
Private Declare Function A_Get_Graphic_ColorBMP Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal x As Long, ByVal y As Long, ByVal mem_mode As Long, ByVal format As Byte, ByVal filename As String) As Long
Private Declare Function A_Load_Graphic Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal x As Long, ByVal y As Long, ByVal Graphic_name As String) As Long
Private Declare Function A_Del_Graphic Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal mem_mode As Long, ByVal graphic As String) As Long
Private Declare Function A_Set_Backfeed Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal back As Long) As Long
Private Declare Function A_Set_BMPSave Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal nSave As Long, ByVal pstrBMPFName As String) As Long
Private Declare Function A_Set_Cutting Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal cutting As Long) As Long
Private Declare Function A_Set_Darkness Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal darkness As Integer) As Integer
Private Declare Function A_Set_DebugDialog Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal nEnable As Integer) As Integer
Private Declare Function A_Set_Feed Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal rate As Byte) As Long
Private Declare Function A_Set_Form Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal formfile As String, ByVal form_name As String, ByVal mem_mode As Long) As Long
Private Declare Function A_Set_Gap Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal gap As Long) As Long
Private Declare Function A_Set_Margin Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal position As Integer, ByVal margin As Integer) As Integer
Private Declare Function A_Set_Prncomport Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal baud As Integer, ByVal parity As Integer, ByVal data As Integer, ByVal sstop As Integer) As Integer
Private Declare Function A_Set_Prncomport_PC Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal nBaudRate As Integer, ByVal nByteSize As Integer, ByVal nParity As Integer, ByVal nStopBits As Integer, ByVal nDsr As Integer, ByVal nCts As Integer, ByVal nXonXoff As Integer) As Long
Private Declare Function A_Set_Sensor_Mode Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal ttype As Byte, ByVal continuous As Long) As Long
Private Declare Function A_Set_Speed Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal speed As Byte) As Long
Private Declare Function A_Set_Syssetting Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal transfer As Integer, ByVal cut_peel As Integer, ByVal length As Integer, ByVal zero As Integer, ByVal pause As Integer) As Integer
Private Declare Function A_Set_Unit Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal unit As Byte) As Long
Private Declare Function A_Set_Logic Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal Logic As Long) As Long
Private Declare Function A_Set_ProcessDlg Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal nShow As Integer) As Integer
Private Declare Function A_Set_LabelVer Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal centiInch As Long) As Long
Private Declare Sub A_Clear_Memory Lib [Ô]\PPLA\WINPPLA.DLL[Ô] ()
Private Declare Sub A_Feed_Label Lib [Ô]\PPLA\WINPPLA.DLL[Ô] ()
Private Declare Function A_Get_DLL_Version Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal nShowMessage As Integer) As String
Private Declare Function A_Get_DLL_VersionA Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal nShowMessage As Integer) As Long
Private Declare Function A_Initial_Setting Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal ttype As Integer, ByVal Source As String) As Long
Private Declare Function A_Print_Form Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal width As Long, ByVal height As Long, ByVal copies As Long, ByVal amount As Long, ByVal form_name As String) As Long
Private Declare Function A_GetUSBBufferLen Lib [Ô]\PPLA\Winppla.DLL[Ô] () As Integer
Private Declare Function A_EnumUSB Lib [Ô]\PPLA\Winppla.DLL[Ô] (ByVal buf() As Byte) As Integer
Private Declare Function A_CreateUSBPort Lib [Ô]\PPLA\Winppla.DLL[Ô] (ByVal nPort As Integer) As Integer
Private Declare Function A_CreatePort Lib [Ô]\PPLA\WINPPLA.DLL[Ô] (ByVal nPortType As Integer, ByVal nPort As Integer, ByVal filename As String) As Long

Eu declaro todas as funções da dll e após eu utilizo para no meu código as funções.

vc tem a dll da impresora Winppla.dll
JAILDOCC 11/08/2010 14:42:27
#349998
Se for usar esses comandos da dll ae a codificação tem q ser outra neh?
GERARDA 11/08/2010 17:36:46
#350015
em anexo tem um exemplo que eu usava

mas é pplb

é muito facil

observe que são impressas duas tags

e com o logo logo no começo
JAILDOCC 13/08/2010 11:27:39
#350160
Amigao testei esse codigo q vc me mando mas quando coloco pra rodar aparece erro em duas linhas e não imprimie, quando passa pela função Print B_Set_Darkness(18) da a mensagem the darknessis out of bounds, e quando passa para a função Print B_Prn_Text_TrueType(90, 170, 28, [Ô]WingDings[Ô], 1, 400, 1, 0, 0, [Ô]AA[Ô], [Ô]([Ô]) da a mensagem The default printer DC is created failed, ae na próxima linha da Division by zero.. e não passa mais e nem imprime, sabe o q pode ser , no q estou errando?
JAILDOCC 13/08/2010 11:29:04
#350161
Ja coloquei a dll winpplb.dll e instalei a impressora e nada
GERARDA 13/08/2010 17:14:11
#350205
manda a dll pra eu fazer uns testes

WINPPLA.DLL
WINPPLB.DLL

as vese foi modificada
Página 1 de 2 [12 registro(s)]
Tópico encerrado , respostas não são mais permitidas