设为首页 收藏本站
查看: 932|回复: 0

[经验分享] TSCActiveX.DLL-PHP-Example

[复制链接]

尚未签到

发表于 2018-12-20 09:23:39 | 显示全部楼层 |阅读模式
  How to RegisterTSCActiveX.Dll File.
  Please copy the two DLL files (TSCActiveX.dll, TSCLIB.dll) intothe folder system underthe Windows system disk. Ex: C:\windows\system\.
  Please register the TSCActiveX.dllby the Regsvr32.exe. Ex:
  Then you can program an ASP filewith TSCActiveX.DLL.
  

  ActiveX.Dll Functions Description.
  -------------------------------------------------------------------------------------------------------
  TSCActiveX.TSCLIB.ActiveXabout()
  Description: Display the DLL version on the screen.
  -------------------------------------------------------------------------------------------------------
  TSCActiveX.TSCLIB.ActiveXopenport(ByVal PrinterName AsString)
  Description: Start the Windows printer spool.
  Parameter:
  PrinterName : String, forlocal printer, please specified the printer driver name. For network printer,please specified the UNC path and printer name.
  -------------------------------------------------------------------------------------------------------
  TSCActiveX.TSCLIB.ActiveXdownloadpcx(ByVal Filename AsString, ByVal ImageName As String)
  Description: Download mono PCX graphic files to the printer
  Parameter:
  Filename: string; file name (including file retrieval path)
  ImageName : string,names of files that are to be downloaded in the printer memory (Please usecapital letters).
  -------------------------------------------------------------------------------------------------------
  TSCActiveX.TSCLIB.ActiveXsetup(ByVal LabelWidth As String,ByVal LabelHeight As String, ByVal Speed As String, ByVal Density As String,ByVal Sensor As String, ByVal Vertical As String, ByVal Offset As String)

  Description: Set up label>  Parameter:

  LabelWidth: string, sets up label>
  LabelHeight: string, sets up label>  Speed : string, setsup print speed, (selectable print speeds vary on different printer models)
  1.0: setsprint speed at 1.0"/sec
  1.5: setsprint speed at 1.5"/sec
  2.0: setsprint speed at 2.0"/sec
  3.0: setsprint speed at 3.0"/sec
  4.0: setsprint speed at 4.0"/sec
  6.0: setsprint speed at 6.0"/sec
  8.0: setsprint speed at 8.0"/sec
  10.0: setsprint speed at 10.0"/sec
  Density: string, sets up print density
  0~15,the greater the number, the darker theprinting
  Sensor: string, sets up the sensor type to be used
  0: signifiesthat vertical gap sensor is to be used
  1: signifiesthat black mark sensor is to be used

  Vertical : string, setsup vertical gap>  Offset : string, setsup shift distance of the gap/black mark; unit:: mm; in the case of the averagelabel, set this parameter to be 0.
  -------------------------------------------------------------------------------------------------------
  TSCActiveX.TSCLIB.ActiveXformfeed()
  Description: Skip to nextpage (of label); this function is to be used after setup.
  -------------------------------------------------------------------------------------------------------TSCActiveX.TSCLIB.ActiveXnobackfeed()
  Description: disable thebackfeed function
  -------------------------------------------------------------------------------------------------------TSCActiveX.TSCLIB.ActiveXsendcommand(ByVal command AsString)
  Description: Sendsbuilt-in commands to the bar code printer
  Parameter: Refer toTSPL for details
  -------------------------------------------------------------------------------------------------------
  TSCActiveX.TSCLIB.ActiveXclearbuffer()
  Description: Clearprinter’s image buffer.
  -------------------------------------------------------------------------------------------------------

  TSCActiveX.TSCLIB.ActiveXwindowsfont(ByValX As Long, ByVal Y As Long, ByVal Fontheight As Long, ByVal Rotation As Long,ByVal Fontstyle As Long, ByVal Fontunderline As Long, ByVal>  Description: UseWindows font to print text.
  Parameter:
  X: Integer, thestarting point of the text along the X direction, given in points
  Y: Integer, thestarting point of the text along the Y direction, given in points

  Fontheight: Integer, the font>  Rotation:Integer, rotation in counter clockwise direction
  0 -> 0degree
  90-> 90 degree
  180-> 180degree
  270-> 270degree
  Fontstyle: Integer, font style
  0-> Normal
  1-> Italic
  2-> Bold
  3-> Boldand Italic
  Fontunderline: Integer, font with underline
  0-> Withoutunderline
  1-> Withunderline

  FaceName : String, fonttype>  TextContent: String, text to be printed.
  -------------------------------------------------------------------------------------------------------

  TSCActiveX.TSCLIB.ActiveXbarcode(ByValX As String, ByVal Y As String, ByVal CodeType As String, ByVal>  Description: Usebuilt-in bar code formats to print
  Parameter:
  X: string; thestarting point of the bar code along the X direction, given in points (of 200DPI, 1 point=1/8 mm; of 300 DPI, 1point=1/12 mm)
  Y: string; thestarting point of the bar code along the Y direction, given in points (of 200DPI, 1 point=1/8 mm; of 300 DPI, 1 point=1/12 mm)
  CodeType: string
  128 :              Code 128, switching code subset A, B, C automatically
  128M :               Code 128, switching code subset A,B, C manually.
  EAN128 :      Code 128, switching code subset A, B, Cautomatically
  25 :             Interleaved 2 of 5
  25C :          Interleaved 2 of 5 with check digits
  39 :             Code 39
  39C :          Code 39 with check digits
  93 :             Code 93
  EAN13 :     EAN 13
  EAN13+2 :        EAN 13 with 2 digits add-on
  EAN13+5 :        EAN 13 with 5 digits add-on
  EAN8 :               EAN 8
  EAN8+2 :   EAN 8 with 2 digits add-on
  EAN8+5 :   EAN 8 with 5 digits add-on
  CODA :        Codabar
  POST :              Postnet
  UPCA :              UPC-A
  UPCA+2 :  UPC-A with 2 digits add-on
  UPCA+5 :  UPC-A with 5 digits add-on
  UPCE :              UPC-E
  UPCE+2 :  UPC-E with 2 digits add-on
  UPCE+5 :  UPC-E with 5 digits add-on

  Height: string; sets up bar code>  Readable : string, setsup whether to print human recognizable interpretation (text) or not.
  0: prints nointerpretation
  1: printsinterpretation
  Rotation: string; sets up rotation degrees
  0:          rotates 0 degree
  90:       rotates 90 degrees
  180:     rotates180 degrees
  270:     rotates 270 degrees
  Narrow: string; sets up narrow bar ratio, refer to TSPL user's manual
  Wide :string; sets up narrow bar ratio, refer to TSPL user's manual
  Code :string; bar code content
  -------------------------------------------------------------------------------------------------------
  TSCActiveX.TSCLIB.ActiveXprinterfont(ByValX As String, ByVal Y As String, ByVal FontName As String, ByVal Rotation AsString, ByVal Xmul As String, ByVal Ymul As String, ByVal Content As String)
  Description: Useprinter built-in fonts to print
  Parameter:
  X: string; thestarting point of text (character string) along the X direction, given inpoints (of 200 DPI, 1 point=1/8 mm; of 300 DPI, 1 point=1/12 mm)
  Y: string; thestarting point of text (character string) along the Y direction, given inpoints (of 200 DPI, 1 point=1/8 mm; of 300 DPI, 1 point=1/12 mm)
  FontName : string; built-in font type name, 12kinds in sum
  1: 8*/12 dots
  2: 12*20 dots
  3: 16*24 dots
  4: 24*32 dots
  5: 32*48 dots
  TST24.BF2: Traditional Chinese 24*24
  TST16.BF2: Traditional Chinese 16*16
  TTT24.BF2: TraditionalChinese 24*24 (Telecommunication Code)
  TSS24.BF2: Simplified Chinese 24*24
  TSS16.BF2: Simplified Chinese 16*16
  K: Japan, Korean font 24*24,
  L: Japan Korean font16*16
  Rotation : string; setsup the rotation degree of the text (character string)
  0: rotates 0 degree
  90: rotate 90 degrees
  180: rotate 180 degrees
  270: rotate 270 degrees
  Xmul : string; setsup the magnification rate of text (character string) along the X direction,range: 1~8
  Ymul : string; setsup the magnification rate of text (character string) along the Y direction,range: 1~8
  Content : string; prints the content of text(character string)
  -------------------------------------------------------------------------------------------------------
  TSCActiveX.TSCLIB.ActiveXprintlabel(ByValNumberOfSet As String, ByVal NumberOfCopy As String)
  Description:Print label content
  Parameter:
  NumberOfSet: string; sets up the number of label sets
  NumberOfCopy: string, sets up the number of print copies
  -------------------------------------------------------------------------------------------------------
  TSCActiveX.TSCLIB.ActiveXcloseport()
  Description: Close Windows printer spool.


运维网声明 1、欢迎大家加入本站运维交流群:群②:261659950 群⑤:202807635 群⑦870801961 群⑧679858003
2、本站所有主题由该帖子作者发表,该帖子作者与运维网享有帖子相关版权
3、所有作品的著作权均归原作者享有,请您和我们一样尊重他人的著作权等合法权益。如果您对作品感到满意,请购买正版
4、禁止制作、复制、发布和传播具有反动、淫秽、色情、暴力、凶杀等内容的信息,一经发现立即删除。若您因此触犯法律,一切后果自负,我们对此不承担任何责任
5、所有资源均系网友上传或者通过网络收集,我们仅提供一个展示、介绍、观摩学习的平台,我们不对其内容的准确性、可靠性、正当性、安全性、合法性等负责,亦不承担任何法律责任
6、所有作品仅供您个人学习、研究或欣赏,不得用于商业或者其他用途,否则,一切后果均由您自己承担,我们对此不承担任何法律责任
7、如涉及侵犯版权等问题,请您及时通知我们,我们将立即采取措施予以解决
8、联系人Email:admin@iyunv.com 网址:www.yunweiku.com

所有资源均系网友上传或者通过网络收集,我们仅提供一个展示、介绍、观摩学习的平台,我们不对其承担任何法律责任,如涉及侵犯版权等问题,请您及时通知我们,我们将立即处理,联系人Email:kefu@iyunv.com,QQ:1061981298 本贴地址:https://www.yunweiku.com/thread-653434-1-1.html 上篇帖子: PHP学习笔记【9】 下篇帖子: 自己写的php数据库类
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

扫码加入运维网微信交流群X

扫码加入运维网微信交流群

扫描二维码加入运维网微信交流群,最新一手资源尽在官方微信交流群!快快加入我们吧...

扫描微信二维码查看详情

客服E-mail:kefu@iyunv.com 客服QQ:1061981298


QQ群⑦:运维网交流群⑦ QQ群⑧:运维网交流群⑧ k8s群:运维网kubernetes交流群


提醒:禁止发布任何违反国家法律、法规的言论与图片等内容;本站内容均来自个人观点与网络等信息,非本站认同之观点.


本站大部分资源是网友从网上搜集分享而来,其版权均归原作者及其网站所有,我们尊重他人的合法权益,如有内容侵犯您的合法权益,请及时与我们联系进行核实删除!



合作伙伴: 青云cloud

快速回复 返回顶部 返回列表