看看:关于C#调用外部DLL动态链接库的问题!
                 	
                        发表在C#图书答疑
                        2008-10-23                                                
                    		
                                                                            	
                        
                        
                    
                    
                    	是否精华
                    	是
                    	否
                    
                    
                    
                            版块置顶:
                            是
                            否
                        
                    
                                           using System;
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;
using Timer = System.Timers.Timer;
using System.Runtime.InteropServices;
using NHTSS.ClientApp.RWIC;
using System.Text;
namespace NHTSS.ClientApp.RWIC.MDI
{
/// <summary>
/// FormIcManager 的摘要说明。
/// </summary>
public class FormIcManager : System.Windows.Forms.Form
{
[DllImport("dcrf32.dll")]
public static extern int dc_init(Int16 port,long baud); //初试化
[DllImport("dcrf32.dll")]
public static extern int dc_exit(int icdev);
[DllImport("dcrf32.dll")]
public static extern int dc_reset(int icdev,uint sec);
[DllImport("dcrf32.dll")]
public static extern int dc_request(int icdev,char _Mode,ref uint TagType);
.....
			
}
	
}
这是visual c# 的定义方法,用C#呢?要怎么改?
                
        	
        
        
    using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;
using Timer = System.Timers.Timer;
using System.Runtime.InteropServices;
using NHTSS.ClientApp.RWIC;
using System.Text;
namespace NHTSS.ClientApp.RWIC.MDI
{
/// <summary>
/// FormIcManager 的摘要说明。
/// </summary>
public class FormIcManager : System.Windows.Forms.Form
{
[DllImport("dcrf32.dll")]
public static extern int dc_init(Int16 port,long baud); //初试化
[DllImport("dcrf32.dll")]
public static extern int dc_exit(int icdev);
[DllImport("dcrf32.dll")]
public static extern int dc_reset(int icdev,uint sec);
[DllImport("dcrf32.dll")]
public static extern int dc_request(int icdev,char _Mode,ref uint TagType);
.....
}
}
这是visual c# 的定义方法,用C#呢?要怎么改?

 
	
                                                 VIP会员
VIP会员 购物车
购物车

 私信
                         私信 
                     发表新帖
发表新帖 立即签到
立即签到 
        		  
        		 
         		 关注
关注
                  回复
 回复 支持(
                	支持( 反对(
                    反对( 
                







 
                     
                     
					 
						 
						 
						 
						