Presentation is loading. Please wait.

Presentation is loading. Please wait.

Plus Series DLL Introduction. DLL Compare for Plus Series DLL Item EZ2000.dllEZWeb.dll (for.Net) OS supportWindow 98 or latest (32bits) Windows 98 or.

Similar presentations


Presentation on theme: "Plus Series DLL Introduction. DLL Compare for Plus Series DLL Item EZ2000.dllEZWeb.dll (for.Net) OS supportWindow 98 or latest (32bits) Windows 98 or."— Presentation transcript:

1 Plus Series DLL Introduction

2 DLL Compare for Plus Series DLL Item EZ2000.dllEZWeb.dll (for.Net) OS supportWindow 98 or latest (32bits) Windows 98 or latest Windows XP or latest Device DriverNo neededNeeded.Net framework 2.0 or latest No needed Needed Network support NoBy printer share

3 API List I DLL API EZ2000.dllEZWeb.dll (for.Net) openport ●●● beginjob ○ ●● sendcommand ●●● intloadimage ●●● extloadimage ●●● closeport ●●● endjob ○ ●● ectextout ●●● getjobcount ○ ●●

4 API List II DLL API EZ2000.dllEZWeb.dll (for.Net) ectextoutr ●●● ectextdownload ●●● putimage ●●● downloadimage ●●● ectextoutfine ○ ●● setup ● ○○ Isready ● ○○ setbaudrate ● ○○ ● support ○ no support

5 EZ2000 DLL Flow Chart Begin openport parameter : 0~6 6 is USB setbaurdrate (serial port only) isready unnecessary sendcommand (or more API) closeport End

6 EZWeb DLL Flow Chart Begin openport parameter : printer name in [control panel]  [printers] beginjob sendcommand (or more API) closeport End endjob

7 FoxPro 5.0 for Windows 95 * PROGRAM FILE NAME :EZTT.PRG path="C:\EZ2\WIN95\EZTT95.DLL" declare mb[10] value=0 i=0 j=0 for i=1 to 10 mb[i]=0 next SET LIBRARY TO c:\vfp\foxtools.fll ADDITIVE mb [1]= RegFn32("openport","C","",path) mb [2] = RegFn32("setup","IIIIII","",path) mb [3] = RegFn32("closeport","","",path) mb [4] = RegFn32("sendcommand","C","",path) mb [5] = RegFn32("intloadimage","CCC","",path) mb [6] = RegFn32("extloadimage","CCC","",path) mb [7] = RegFn32("isready","","I",path) for j=1 to 7 if mb[j]= -1 RELEASE LIBRARY C:\vfp\FoxTools.FLL WAIT WINDOW "FAILURE!!" NOWAIT RETURN endif next value = CallFn(mb[7]) if value=1 = CallFn(mb[1],"0") = CallFn(mb[2],75,5,2,0,3,0) = CallFn(mb[4],"^P2") = CallFn(mb[5],"aeer.pcx","aeer","pcx") = CallFn(mb[4],"^L") = CallFn(mb[4],"BA,40,40,2,4,25,0,1,12345") = CallFn(mb[4],"Y40,100,aeer") = CallFn(mb[4],"E") else wait windows "PRINTER ERROR" nowait endif RELEASE LIBRARY C:\vfp\FoxTools.FLL

8 Visual Basic 4.0 Private Declare Sub openport Lib "c:\ez2\win31\eztt.dll" (ByVal no$) Private Declare Sub setup Lib "c:\ez2\win31\eztt.dll" (ByVal a%, ByVal b%, ByVal c%, ByVal d%, ByVal e%, ByVal f%) Private Declare Sub sendcommand Lib "c:\ez2\win31\eztt.dll" (ByVal command$) Private Declare Sub intloadimage Lib "c:\ez2\win31\eztt.dll" (ByVal filename$, ByVal image_name$, ByVal image_type$) Private Declare Sub extloadimage Lib "c:\ez2\win31\eztt.dll" (ByVal filename$, ByVal image_name$, ByVal image_type$) Private Declare Sub closeport Lib "c:\ez2\win31\eztt.dll" () Private Declare Function isready% Lib "c:\ez2\win31\eztt.dll" () Private Sub cmExit_Click() End End Sub Private Sub cmPrint_Click() Call openport("0") If isready = 0 Then MsgBox "Printer is not ready.", 16, "Printer status"

9 Visual Basic 4.0 Else Call setup(20, 10, 2, 1, 2, 0) Call sendcommand("^P1") Call intloadimage("c:\ez2\win31\aeer.pcx", "aeer", "pcx") Call sendcommand("^L") Call sendcommand("AD,10,30,1,1,3,0," & txText.Text) Call sendcommand("BE,10,100,3,3,50,0,1," & txBarcode.Text) Call sendcommand("Y400,20,aeer") Call sendcommand("E") End If Call closeport

10 VB.Net Example Imports EZWeb Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim gPrinter As New GodexPrinter() If OpenFileDialog1.ShowDialog() = Windows.Forms.DialogResult.Cancel Then Return End If gPrinter.openport(ComboBox1.Text) gPrinter.beginjob(Integer.Parse(txtLabelLength.Text), Integer. Parse(cbDarkness.Text), Integer.Parse(cbSpeed.Text), 2, 3, 3)

11 VB.Net Example gPrinter.sendcommand("^L" + Chr(13) + Chr(10)) gPrinter.putimage(10, 80, OpenFileDialog1.FileName, 0) gPrinter.sendcommand(Chr(13) + Chr(10) + "E" + Chr(13) + Chr(10)) gPrinter.endjob() gPrinter.closeport() End Sub

12 Borland Delphi Example const DLLNAME='ez2000.dll'; procedure openport (no:string); stdcall;external DLLNAME; function readusb (c:PChar;d:PInteger):integer; stdcall;external DLLNAME; procedure sendcommand (command:string); stdcall;external DLLNAME; procedure setbaudrate (n:integer); stdcall;external DLLNAME; function readchar():integer; stdcall;external DLLNAME; procedure closeport; stdcall;external DLLNAME;

13 Borland Delphi Example VAR i:integer; pi:PInteger; Pws :string; ID:array[0..1024] of Char; pID : PChar; portno:integer; begin portno:=combobox1.ItemIndex; // port choose 0,1,2,3,4,5,6 case portno of 6 : begin openport(inttostr(portno)); setbaudrate(9600); // ~B feedback version sendcommand('~B'); Delay(500); // USB port read pi := @i; pID := @ID; readusb(pID, pi); showMessage(ID);// Show version closeport; end;

14


Download ppt "Plus Series DLL Introduction. DLL Compare for Plus Series DLL Item EZ2000.dllEZWeb.dll (for.Net) OS supportWindow 98 or latest (32bits) Windows 98 or."

Similar presentations


Ads by Google