Solved

how to use the :SetCommState, CommConfigDialog?

Posted on 1997-12-04
4
532 Views
Last Modified: 2013-11-20
I can't compile when i use the SetCommState. Where to put it and how to write Char to COM3?
0
Comment
Question by:hercules120197
  • 3
4 Comments
 

Author Comment

by:hercules120197
ID: 1311575
I need a sample in MSDEV4.x and more.
0
 
LVL 1

Accepted Solution

by:
IgorGrebnev earned 20 total points
ID: 1311576
Go to the stdafx.h and delete following #define
#define VC_EXTRALEAN            // Exclude rarely-used stuff from Windows headers

This VC_EXTRALEAN exclude declaration for SetCommState. Eliminate this define.
You can write character to COM with WriteFile. You careat the handle of the port with CreateFile function and supply the name of the file "COM3"
Yours, Igor
Yors Igor
0
 

Author Comment

by:hercules120197
ID: 1311577
Where can i use the comment SetCommState,CommConfigDialog.The CommConfigDialog needs a HWND and i m not understanding from which function or class.
0
 

Author Comment

by:hercules120197
ID: 1311578
Where can i use the comment SetCommState,CommConfigDialog.The CommConfigDialog needs a HWND and i m not understanding from which function or class.
0

Featured Post

Highfive Gives IT Their Time Back

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Decoding 32 bit binary streams 6 31
either24  challenge 19 84
Use of condition with 'serial' in ansible 2 36
Not needed 13 53
In this article, I'll describe -- and show pictures of -- some of the significant additions that have been made available to programmers in the MFC Feature Pack for Visual C++ 2008.  These same feature are in the MFC libraries that come with Visual …
Have you tried to learn about Unicode, UTF-8, and multibyte text encoding and all the articles are just too "academic" or too technical? This article aims to make the whole topic easy for just about anyone to understand.
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
This video discusses moving either the default database or any database to a new volume.

707 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

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now