IMPRIMIR IMAGEM ARGOX PPLA

 Tópico anterior Próximo tópico Novo tópico

IMPRIMIR IMAGEM ARGOX PPLA

VB / VBA

 Compartilhe  Compartilhe  Compartilhe
#349833 - 09/08/2010 16:13:12

JAILDOCC
LAGOA DO OURO
Cadast. em:Janeiro/2006


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

Jaildo C. Carvalho
Desenvolvedor de Sistemas
Visual Basic 6.0

#349869 - 10/08/2010 09:53:07

GERARDA
MONTESIAO
Cadast. em:Maio/2010


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





#349873 - 10/08/2010 10:12:43

JAILDOCC
LAGOA DO OURO
Cadast. em:Janeiro/2006


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.

Jaildo C. Carvalho
Desenvolvedor de Sistemas
Visual Basic 6.0

#349885 - 10/08/2010 13:13:15

GERARDA
MONTESIAO
Cadast. em:Maio/2010


qual seria o modelo de sua impressora



#349904 - 10/08/2010 15:05:52

JAILDOCC
LAGOA DO OURO
Cadast. em:Janeiro/2006


Amigo GERARDA minha impressora é ARGOX OS-214 plus

Jaildo C. Carvalho
Desenvolvedor de Sistemas
Visual Basic 6.0

#349980 - 11/08/2010 12:38:55

GERARDA
MONTESIAO
Cadast. em:Maio/2010


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



#349998 - 11/08/2010 14:42:27

JAILDOCC
LAGOA DO OURO
Cadast. em:Janeiro/2006


Se for usar esses comandos da dll ae a codificação tem q ser outra neh?

Jaildo C. Carvalho
Desenvolvedor de Sistemas
Visual Basic 6.0

#350015 - 11/08/2010 17:36:46

GERARDA
MONTESIAO
Cadast. em:Maio/2010


 Anexos estao visíveis somente para usuários registrados

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



#350160 - 13/08/2010 11:27:39

JAILDOCC
LAGOA DO OURO
Cadast. em:Janeiro/2006


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?

Jaildo C. Carvalho
Desenvolvedor de Sistemas
Visual Basic 6.0

#350161 - 13/08/2010 11:29:04

JAILDOCC
LAGOA DO OURO
Cadast. em:Janeiro/2006


Ja coloquei a dll winpplb.dll e instalei a impressora e nada

Jaildo C. Carvalho
Desenvolvedor de Sistemas
Visual Basic 6.0

#350205 - 13/08/2010 17:14:11

GERARDA
MONTESIAO
Cadast. em:Maio/2010


Última edição em 13/08/2010 17:15:35 por GERARDA

manda a dll pra eu fazer uns testes

WINPPLA.DLL
WINPPLB.DLL

as vese foi modificada



 Tópico anterior Próximo tópico Novo tópico


Para responder este tópico o login é requerido
Se você já possui uma conta de usuário por favor faça seu login
Se você não possui uma conta de usuário use a opção Criar usuário