|
|
|||||||||
|
|||||||||
|
|||||||||
| |
||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Hi All,
I am a novice in VB development. I want to capture data from one of the Chemical analyzer machines which has it's printer within itself, but it does has a comm port. Now I want to capture data sent by it's comm port on my PC. I have the requisit cable but am not able to receive any data. Therefor I tried writing this script and sent some data using print command from dos prompt on com port. But to my dismay I am not getting connected. If I send data first and then try to connect it says port is open and doesn't let me go ahead. and if I send data and then without using PortOpen try to access the port it says the port is not open. And if I open port before sending the data then it doesn't let me send the data on the port only. Can somebody help me how to resole this issue. The code is as follows: MSComm.Settings = "9600, n, 8 , 1" MSComm.CommPort = 1 PortStatus = MSComm.PortOpen If Not PortStatus = True Then MSComm.PortOpen = True End If Text1 = MSComm.PortOpen MSComm.PortOpen = False Thanks in Advance, Hoping to receive some answer. You can even send me reply directly on my mail ID sidadirat@hotmail.com Siddhartha |
|
#2
|
|||
|
|||
|
Try testing your communications with the device using hyperterminal. If you can talk to your machine properly with hyperterminal then work on your code. Maybe the requisite cable isn't
![]()
__________________
====== Doug G ====== I didn't attend the funeral, but I sent a nice letter saying I approved of it. --Mark Twain |
![]() |
| Viewing: ASP Free Forums > Programming > Visual Basic Programming > Reading data from Comm Port |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|