Once the ::WaitCommEvent() is called such as this:
::SetCommMask(m_hCommPort,EV_RXCHAR);
::WaitCommEvent(apThis->m_hCommPort,&dwEventMask, NULL );
//This will block the thread until of course there is data at the receiving
//then ::ReadFile() is called to read the data until no more is read.
do
{
::ReadFile(apThis->m_hCommPort,&byrcv,1,&dwBytesRead, NULL)
}while (dwBytesRead >0)
//so once ::ReadFile() is done, it will loopback to ::WaitCommEvent()
//but this time, ::WaitCommEvent() is no longer blocking which is not
//good. So how can I reset ::WaitCommEvent() so that it will be waiting
//for new receiving data again. Notice that is is non-overlapped operations.