PB开发二维条码的方法

来源:互联网 发布:爱课程软件 编辑:程序博客网 时间:2024/04/24 14:40

采用PowerBuilder调用EnCodePdf.dll实现PDF417条码编制,先将EnCodePdf.dll拷贝至微机上,再在PB中申明以下接口程序,在程序中函数的调用类似VC的操作。

接口函数的申明如下:

Ø        Function int InitRead( longhcallwnd, string pathname) library "EnCodePdf.dll"

Ø        Function int CloseRead()library"EnCodePdf.dll"

Ø        SubRoutine SetPdfConFile (string confile ) library "EnCodePdf.dll"

Ø        Function string EnPdfText (stringtxtData, string outfile) library "EnCodePdf.dll"

Ø        Function string EnCodePdf (stringtxtfile, string outfile) library "EnCodePdf.dll"

Ø        Function string MakePdf417 (stringtxtfile, string imgfile, string othfile, string outfile) library"EnCodePdf.dll"

 

应用调用例子如下:

     string strText=’福州博智成软件开发有限公司’;

     SetPdfConFile(‘MakeBarCode.ini’);

     Pdfname=EnPdfText( strText,’c:\pdf417.bmp’); 

其它Qr_Code,DataMatrix和汉息条码可以到官网取得:http://www.FzBozc.com


原创粉丝点击