就是微软自带的 先在visual stadio.NET的“项目”-“添加引用”-“com”菜单加入Microsoft Comm Control6.0组件,并在“工具”-“自定义工具箱”中选择Microsoft Communication Control组件,这样就可以在工具箱中找到MSComm控件。哦,忘记声明,这个组件需要安装VC6.0才有。
代码如下: using ; using .Text; using .Drawing; using .Collections; using .ComponentModel; using .Windows.Forms; using .Data; complc { /// <summary> /// Form1 摘要介绍说明 /// </summary> [Page] public comForm : .Windows.Forms.Form { private AxMSCommLib.AxMSComm axMSComm1; private .Windows.Forms.TextBox textBox1; private .Windows.Forms.TextBox textBox2; private .Windows.Forms.Button button1; private .Windows.Forms.Button button2; private .Windows.Forms.Label label1; private .Windows.Forms.Label label2; /// <summary> /// 必需设计器变量
regsvr32 "MSCOMM32.OCX" 可以直接拖到运行窗口里去在vs里添加引用MSCOMM32.OCX然后就可以引用MSComm 不过这个版本的,前面没Ax前缀~~~~~~~~~~~~~~~
http://www.cnblogs.com/zpjwys/archive/2009/02/05/1384626.html
先在visual stadio.NET的“项目”-“添加引用”-“com”菜单加入Microsoft Comm Control6.0组件,并在“工具”-“自定义工具箱”中选择Microsoft Communication Control组件,这样就可以在工具箱中找到MSComm控件。哦,忘记声明,这个组件需要安装VC6.0才有。
using ;
using .Text;
using .Drawing;
using .Collections;
using .ComponentModel;
using .Windows.Forms;
using .Data;
complc
{
/// <summary>
/// Form1 摘要介绍说明
/// </summary> [Page]
public comForm : .Windows.Forms.Form
{
private AxMSCommLib.AxMSComm axMSComm1;
private .Windows.Forms.TextBox textBox1;
private .Windows.Forms.TextBox textBox2;
private .Windows.Forms.Button button1;
private .Windows.Forms.Button button2;
private .Windows.Forms.Label label1;
private .Windows.Forms.Label label2;
/// <summary>
/// 必需设计器变量
AXmscommlib.dl有谁知道在哪能下到这两个dll文件
要是找到,我加分