Click here to Skip to main content
15,902,884 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Kind question Pin
coolice20029-Nov-08 9:03
coolice20029-Nov-08 9:03 
GeneralRe: Kind question Pin
Code-o-mat9-Nov-08 11:27
Code-o-mat9-Nov-08 11:27 
QuestionGetting notification for changes of files in the system Pin
Green Fuze9-Nov-08 7:18
Green Fuze9-Nov-08 7:18 
AnswerRe: Getting notification for changes of files in the system Pin
Mark Salsbery9-Nov-08 8:26
Mark Salsbery9-Nov-08 8:26 
GeneralRe: Getting notification for changes of files in the system Pin
Green Fuze9-Nov-08 8:54
Green Fuze9-Nov-08 8:54 
AnswerRe: Getting notification for changes of files in the system Pin
Hamid_RT9-Nov-08 9:10
Hamid_RT9-Nov-08 9:10 
AnswerRe: Getting notification for changes of files in the system Pin
Jijo.Raj9-Nov-08 21:30
Jijo.Raj9-Nov-08 21:30 
QuestionWriteFile returns non-zero(Success) NumberBytesWritten is 0 Pin
Shiva Prasad9-Nov-08 2:48
Shiva Prasad9-Nov-08 2:48 
Hi,

I am running a WinCE6.0 Stream interface Driver on a DTE device which will open a handle to Serial port which is
connected to a modem.WriteFile API returns non-zero Value, but NumberofbytesWritten parameters is coming as Zero.

The Windows CE 6.0 device is a DTE terminal and when connected to PC (Another DTE)) over NULL Modem cable with hyperterminal, all the data from the are seen on the hyperterminal, and WriteFile API fills the NumberofbytesWritten is exactly the same as the
bytestoWrite.

When the CE6.0 DTE device is connected to DCE Modemdevice using a Straight serial cable, WriteFile API
is succedding by returning Non-Zero Value, but NumberofbytesWritten parameters is coming as Zero.

The following is the DCB in the driver:
dcb.BaudRate = m_BaudRate;(115200)
dcb.fBinary = TRUE;
dcb.fParity = TRUE;
dcb.fOutxCtsFlow = TRUE;
dcb.fOutxDsrFlow = FALSE;
dcb.fDtrControl = DTR_CONTROL_ENABLE;
dcb.fDsrSensitivity = FALSE;
dcb.fTXContinueOnXoff = TRUE;
dcb.fOutX = FALSE;
dcb.fInX = FALSE;
dcb.fErrorChar = FALSE;
dcb.fNull = FALSE;
dcb.fRtsControl = RTS_CONTROL_HANDSHAKE;
dcb.fAbortOnError = FALSE;
dcb.ByteSize = 8;
dcb.Parity = NOPARITY;
dcb.StopBits = ONESTOPBIT;
Also, I am setting EscapeCommFunction(m_hCOMHandle,SETDTR);

On the hyperteminal I have the following setting:
baudrate = 115200
Data bit = 8
Parity=None
StopBit=1
FlowControl=None

Also, with the same hyperterminal setting with PC(Hyperterminal) connected to Modem over Straight SErial cable,
I am able to fire the AT Commands from the PC(hyperterminal) to the modem.

Also CommTimeout, I have set the following:

CT.ReadIntervalTimeout = MAXDWORD;
CT.ReadTotalTimeoutMultiplier = 0;
CT.ReadTotalTimeoutConstant = 0;
CT.WriteTotalTimeoutMultiplier = 0;
CT.WriteTotalTimeoutConstant = 100;

-Can a timeout issue cause WriteFile Still succeed and Numberof Bytes Written as zero?
- In hyperterminal Flow Control None, what are the Flow control affected in the DCB?

Can somebody give me some hints on the same.

Thanks..
QuestionHow to get CDocument pointer in Dialog class Pin
Max++8-Nov-08 23:58
Max++8-Nov-08 23:58 
AnswerRe: How to get CDocument pointer in Dialog class Pin
Mark Salsbery9-Nov-08 6:21
Mark Salsbery9-Nov-08 6:21 
QuestionHow to detect whether a COM port is available or not ? Pin
brucewayn8-Nov-08 21:45
brucewayn8-Nov-08 21:45 
AnswerRe: How to detect whether a COM port is available or not ? Pin
Rolf Kristensen9-Nov-08 1:29
Rolf Kristensen9-Nov-08 1:29 
QuestionHow can I create a working thread in a MFC regular dll Pin
W.Kim 19878-Nov-08 20:51
W.Kim 19878-Nov-08 20:51 
AnswerRe: How can I create a working thread in a MFC regular dll Pin
Mark Salsbery9-Nov-08 6:30
Mark Salsbery9-Nov-08 6:30 
GeneralRe: How can I create a working thread in a MFC regular dll Pin
W.Kim 19879-Nov-08 14:07
W.Kim 19879-Nov-08 14:07 
GeneralRe: How can I create a working thread in a MFC regular dll Pin
Mark Salsbery9-Nov-08 14:10
Mark Salsbery9-Nov-08 14:10 
GeneralRe: How can I create a working thread in a MFC regular dll [modified] Pin
W.Kim 19879-Nov-08 18:04
W.Kim 19879-Nov-08 18:04 
GeneralRe: How can I create a working thread in a MFC regular dll Pin
Iain Clarke, Warrior Programmer9-Nov-08 22:25
Iain Clarke, Warrior Programmer9-Nov-08 22:25 
GeneralRe: How can I create a working thread in a MFC regular dll Pin
W.Kim 198710-Nov-08 3:06
W.Kim 198710-Nov-08 3:06 
GeneralRe: How can I create a working thread in a MFC regular dll Pin
Mark Salsbery10-Nov-08 4:53
Mark Salsbery10-Nov-08 4:53 
GeneralRe: How can I create a working thread in a MFC regular dll Pin
Mark Salsbery10-Nov-08 5:00
Mark Salsbery10-Nov-08 5:00 
QuestionPointer symbol position and constant member functions Pin
Christian Flutcher8-Nov-08 16:55
Christian Flutcher8-Nov-08 16:55 
AnswerRe: Pointer symbol position and constant member functions Pin
Saurabh.Garg8-Nov-08 18:55
Saurabh.Garg8-Nov-08 18:55 
GeneralRe: Pointer symbol position and constant member functions Pin
Christian Flutcher9-Nov-08 5:35
Christian Flutcher9-Nov-08 5:35 
AnswerRe: Pointer symbol position and constant member functions Pin
toxcct9-Nov-08 3:05
toxcct9-Nov-08 3:05 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.