?
Solved

MSComm Equivalent?

Posted on 2005-03-25
10
Medium Priority
?
1,192 Views
Last Modified: 2008-01-16
Hi all,
         I have been developing in VB6 for 3 years now.... Most of my software involve reading and writing from Serial Port.... I have used MSComm control from VB6.... I have just recently decided to learn VB.NET 2003.... Can you suggest an equivalent of MSComm control in VB.NET? In my programming I am using OnComm event for reading the Port. Is there anything similar to this one?

Imran
0
Comment
Question by:imarshad
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
  • 2
  • +2
10 Comments
 
LVL 8

Assisted Solution

by:mani_sai
mani_sai earned 1600 total points
ID: 13630804
0
 
LVL 8

Accepted Solution

by:
mani_sai earned 1600 total points
ID: 13630845
0
 
LVL 13

Author Comment

by:imarshad
ID: 13630923
Yes I have seen most of these links before..... The reason I am more concerned is that I am developing a software both for Windows XP and Windows CE.NET..... Since using MSComm I was able to port my same code for both the applications (In VB6 and eVB)..... So Now I want to be sure that it must run on both targets(XP and CE.NET)....Also I will love to have most of my MSCOmm code directly used in VB.NET..... I have heard that MSComm control can directly be used in VB.NET..... How can this be done??? Is it safe?

Imran
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 96

Assisted Solution

by:Bob Learned
Bob Learned earned 400 total points
ID: 13631666
You can use the MSComm control through COM interoperability, but there is no guarantee that it will work 100%.  VB.NET generates a wrapper class for the control, which may or may not expose all the functionality of the original, and may produce some complicated bugs.  What that means is that safety is not guaranteed.

Bob
0
 
LVL 13

Author Comment

by:imarshad
ID: 13632439
>> What that means is that safety is not guaranteed.

So what is the general practice of reading/writing to serial Ports in VB.NET 2003? For example can I trust the following code suggested by mani as I have trusted MSComm control in VB6??

http://www.codeworks.it/net/VBNetRs232.htm

Also will this one run on Windows CE.NET?

Imran
0
 
LVL 4

Expert Comment

by:fceledon
ID: 13633644
Wait for VS 2005 ... comm port handling will be in the  "my" all-in-one object. You can try the beta version.

http://msdn2.microsoft.com/library/11bxex12.aspx

http://msdn2.microsoft.com/library/e4560dx9.aspx

fc:)
0
 
LVL 8

Expert Comment

by:bman9111
ID: 13721033
yea I have decide to continue using the mscomm1, I haven't had a problem yet.........
0
 
LVL 8

Expert Comment

by:bman9111
ID: 13740298
I did get microsoft example to work finally like mscomm1. U should take a look at it sometime. It really isn't just for modems

It took me awhile, but I ended up getting what I want......
0
 
LVL 13

Author Comment

by:imarshad
ID: 13740420
Which Microsoft example are you using?

Imran
0
 
LVL 8

Expert Comment

by:bman9111
ID: 13741211
the one from 101 samples
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This tutorial demonstrates one way to create an application that runs without any Forms but still has a GUI presence via an Icon in the System Tray. The magic lies in Inheriting from the ApplicationContext Class and passing that to Application.Ru…
A while ago, I was working on a Windows Forms application and I needed a special label control with reflection (glass) effect to show some titles in a stylish way. I've always enjoyed working with graphics, but it's never too clever to re-invent …
In this video we outline the Physical Segments view of NetCrunch network monitor. By following this brief how-to video, you will be able to learn how NetCrunch visualizes your network, how granular is the information collected, as well as where to f…
NetCrunch network monitor is a highly extensive platform for network monitoring and alert generation. In this video you'll see a live demo of NetCrunch with most notable features explained in a walk-through manner. You'll also get to know the philos…
Suggested Courses

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question