Click here to Skip to main content
14,242,230 members

C / C++ / MFC

 
AnswerRe: Device Running Windows CE 6.0 Pin
Richard MacCutchan4-Jun-19 21:04
protectorRichard MacCutchan4-Jun-19 21:04 
AnswerRe: Device Running Windows CE 6.0 Pin
CPallini4-Jun-19 22:28
mveCPallini4-Jun-19 22:28 
Questionhow i can disable key from keyboard of computer using C language Pin
Member 1447157029-May-19 6:45
memberMember 1447157029-May-19 6:45 
AnswerRe: how i can disable key from keyboard of computer using C language Pin
Victor Nijegorodov29-May-19 8:12
memberVictor Nijegorodov29-May-19 8:12 
AnswerRe: how i can disable key from keyboard of computer using C language Pin
leon de boer31-May-19 17:10
memberleon de boer31-May-19 17:10 
AnswerRe: how i can disable key from keyboard of computer using C language Pin
jschell2-Jun-19 8:42
memberjschell2-Jun-19 8:42 
AnswerRe: how i can disable key from keyboard of computer using C language Pin
David Crow3-Jun-19 9:06
memberDavid Crow3-Jun-19 9:06 
QuestionChange value to a thread Pin
_Flaviu29-May-19 3:24
member_Flaviu29-May-19 3:24 
I indent to use FindFirstChangeNotification in a class static method in order to use it in a thread, something like this:
DWORD WINAPI FilesWatchDogThread(LPVOID lpParam)
{
      HANDLE hFileChange = ::FindFirstChangeNotification((LPCTSTR)lpParam, // folder path
                                    TRUE,
                                    FILE_NOTIFY_CHANGE_FILE_NAME); 
   if(INVALID_HANDLE_VALUE == hFileChange)
   {
      DWORD dwError = ::GetLastError();
      return dwError;
   }
   
   while(TRUE)
   {
      ::WaitForSingleObject(hFileChange, INFINITE);
      // do my job
      ::FindNextChangeNotification(hFileChange);
   }
   return 0;
}

   // somewhere …
   ::CreateThread(NULL, 0, &CMyClass::FilesWatchDogThread, _T("c:\\temp"), 0, NULL);

but how can Itell the thread when a folder to watch has been changed (I mean _T("c:\\temp") change to _T("e:\\whatever")) ? What should I use for that ? CreateEvent or what ?
AnswerRe: Change value to a thread Pin
Victor Nijegorodov29-May-19 5:28
memberVictor Nijegorodov29-May-19 5:28 
GeneralRe: Change value to a thread Pin
_Flaviu29-May-19 21:23
member_Flaviu29-May-19 21:23 
GeneralRe: Change value to a thread Pin
Victor Nijegorodov29-May-19 23:01
memberVictor Nijegorodov29-May-19 23:01 
GeneralRe: Change value to a thread Pin
_Flaviu29-May-19 23:23
member_Flaviu29-May-19 23:23 
GeneralRe: Change value to a thread Pin
Victor Nijegorodov30-May-19 0:46
memberVictor Nijegorodov30-May-19 0:46 
GeneralRe: Change value to a thread Pin
_Flaviu29-May-19 23:26
member_Flaviu29-May-19 23:26 
GeneralRe: Change value to a thread Pin
leon de boer30-May-19 1:30
memberleon de boer30-May-19 1:30 
GeneralRe: Change value to a thread Pin
_Flaviu30-May-19 21:08
member_Flaviu30-May-19 21:08 
GeneralRe: Change value to a thread Pin
_Flaviu30-May-19 22:12
member_Flaviu30-May-19 22:12 
GeneralRe: Change value to a thread Pin
Victor Nijegorodov30-May-19 22:39
memberVictor Nijegorodov30-May-19 22:39 
GeneralRe: Change value to a thread Pin
_Flaviu30-May-19 23:57
member_Flaviu30-May-19 23:57 
GeneralRe: Change value to a thread Pin
Victor Nijegorodov31-May-19 0:01
memberVictor Nijegorodov31-May-19 0:01 
QuestionKnow when a files has been copied Pin
_Flaviu28-May-19 5:36
member_Flaviu28-May-19 5:36 
AnswerRe: Know when a files has been copied Pin
Richard MacCutchan28-May-19 5:50
protectorRichard MacCutchan28-May-19 5:50 
AnswerRe: Know when a files has been copied Pin
Victor Nijegorodov28-May-19 20:37
memberVictor Nijegorodov28-May-19 20:37 
AnswerRe: Know when a files has been copied Pin
Dave Kreskowiak31-May-19 2:49
mveDave Kreskowiak31-May-19 2:49 
QuestionI have 3rd party . OCX file. which loads in HTML scripts and do desired work Pin
Gaurav__Kapoor26-May-19 22:12
memberGaurav__Kapoor26-May-19 22:12 

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.