Solved

how to use the :SetCommState, CommConfigDialog?

Posted on 1997-12-04
4
558 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
[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
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

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

Here is how to use MFC's automatic Radio Button handling in your dialog boxes and forms.  Beginner programmers usually start with a OnClick handler for each radio button and that's just not the right way to go.  MFC has a very cool system for handli…
Introduction: Load and Save to file, Document-View interaction inside the SDI. Continuing from the second article about sudoku.   Open the project in visual studio. From the class view select CSudokuDoc and double click to open the header …
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.
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …

632 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