C#下调用捷宝链接库函数整理

来源:互联网 发布:新手开淘宝网店 编辑:程序博客网 时间:2024/05/29 18:15
 //获取端口号        [DllImport("JB8800.dll", EntryPoint = "hs_state")]        public static extern int hs_state(int number);        //打开端口        [DllImport("JB8800.dll", EntryPoint = "openport")]        public static extern int openport(int port);        //获取文件信息        [DllImport("JB8800.dll", EntryPoint = "getlist")]        public static extern int getlist(int port);        // 文件从掌机下载到计算机        [DllImport("JB8800.dll", EntryPoint = "downfile")]        public static extern int downfile(int port, StringBuilder sb_Filename);        //函数实现从抄表终端上传到上位机        [DllImport("JB8800.dll", EntryPoint = "upload")]        public static extern int upload(int port, StringBuilder filename, int startaddr, int endaddr, int paklen, int compress, int wait);        //函数实现删除抄表终端上的文件        [DllImport("JB8800.dll", EntryPoint = "deletefile")]        public static extern int deletefile(int port, StringBuilder filename);        //函数实现打开的端口  closeport        [DllImport("JB8800.dll", EntryPoint = "closeport")]        public static extern void closeport();        //函数实现机器编号         [DllImport("JB8800.dll", EntryPoint = "getmno")]        public static extern int getmno(int port, StringBuilder mno);

原创粉丝点击