需要有关AxMScomm控制的信息 [英] Need Information regarding AxMScomm control

查看:117
本文介绍了需要有关AxMScomm控制的信息的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,


这是拉胡尔,我较新.我有可以使用Axmscomm控件的项目.

我的项目:
我应该按编号通过GSM调制解调器将一个系统从一个系统复制到另一个系统,并且应该从中读取数据.我应该在带有SQL Server的vb.net中执行此应用程序.

我在谷歌搜索了很多,但我没有得到任何信息.我以为这个论坛对我有帮助.因此,请提供有关此信息.

1.在执行此操作之前,我应该了解哪些信息?
2.如何在我的应用程序中使用Axmscomm控件?
3.我已经使用某些源尝试过该应用程序,但是我得到了 抛出类型为"System.Windows.Forms.AxHost = InvalidActiveXStateException"的异常 错误.如何解决这个问题
请用源指导我.请帮助我:confused:
我迫切需要完成此

预先感谢您

Hi All,


This is Rahul.I''m fresher. I got project to work Axmscomm control.

My project :
I should dail a system from my system to another system through GSM modem by number and i should read the data from it. I should do this application in vb.net with Sql Server.

I have searched a lot in google but i dint get any information. I thought this forum may help me. So please kindly give some information regarding this.

1. What information I should aware of before doing this?
2. How to use Axmscomm Control to my application?
3. I have Tried this application with some source but i''m getting Exception of Type ''System.Windows.Forms.AxHost=InvalidActiveXStateException'' was thrown errors. How to slove this
Please guide me with source.Please Help me:confused:
It is Urgent for me to complete this

Thank You in Advance

推荐答案

你好

我在vb.net中使用mscomm控件,我读取了字节长度的数据,实际上显示的数据为null,我将dim rbuf声明为string,而事件引发的rbuf显示为null,如何解决此问题,
我在下面的mscommcontrol事件代码中发送了我的代码




私有子AxMSComm1_OnComm(ByVal发送者作为对象,ByVal e作为System.EventArgs)处理AxMSComm1.OnComm

选择案例AxMSComm1.CommEvent

案例MSCommLib.OnCommConstants.comEvReceive
rbuf = Asc(rbuf和AxMSComm1.Input)
Label22.Text =修剪(rbuf)
Label14.Text = Len(rbuf)

如果Len(rbuf)= 6,则写入文件(rbuf)
eventcount = eventcount + 1
Label15.Text = eventcount

结束选择
结束子





谢谢
hello

iam using mscomm control in vb.net , i read the data in the length of bytes , actually data showing is null , I declared the dim rbuf as string , while event is raising rbuf it shows null,how to resolve this problem,
i sent my code in the mscommcontrol event code it is in below




Private Sub AxMSComm1_OnComm(ByVal sender As Object, ByVal e As System.EventArgs) Handles AxMSComm1.OnComm

Select Case AxMSComm1.CommEvent

Case MSCommLib.OnCommConstants.comEvReceive
rbuf = Asc(rbuf & AxMSComm1.Input)
Label22.Text = Trim(rbuf )
Label14.Text = Len(rbuf )

If Len(rbuf )= 6 Then writetofile(rbuf )
eventcount = eventcount + 1
Label15.Text = eventcount

End Select
End Sub





Thanks


这篇关于需要有关AxMScomm控制的信息的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆