Hi, My project involves receiving input from a keyboard device. I use "Raw Input" to collect data only from that device. But I also wish other applications NOT to receive data from that device. Anybody can help me? Thanks in advance
Manikandan
Posts
-
raw input only to an application -
Menu in dialogs!Thanks Jose. I also found a easy way to do this something as below, // Get the popup menu which contains the "Lock" menu item. CMenu* mmenu = GetMenu(); CMenu* submenu = mmenu->GetSubMenu(2); submenu->CheckMenuItem(ID_LOCK, (m_bLock)?MF_CHECKED : MF_UNCHECKED | MF_BYCOMMAND); ;P
-
Menu in dialogs!Hi, How to make command UI fuctions like; pCmdUI->SetText, pCmdUI->Enable, pCmdUI->SetCheck to work when we have a menu in dialog? Currently it works for menus in SDI/MDI's but not in dialogs :confused:
-
BSTR*I came to know the problem is within the activeX control itself. I download the latest control and its working fine without errors. Thank you James.
-
BSTR*I receive two errors, 1."Run-time error'9': Subscript out of range" from activeX control itself. 2."Application-defined or object-defined error" thrown by the application.
-
Winsock and MFCI use NDK from the link below, http://www.codeproject.com/internet/ndk.asp?df=100&forumid=1156&exp=0&select=756975 it's just nice;P
-
BSTR*I got to use an activeX control in my VC++ project. When I import the control its wrapper class had a function as below, void CVTSID::Connect(BSTR* RemHost, long* RemPort) { static BYTE parms[] = VTS_PBSTR VTS_PI4; InvokeHelper(0x60030012, DISPATCH_METHOD, VT_EMPTY, NULL, parms, RemHost, RemPort); } I tried to pass the parameters as below, CString str = "192.168.1.155"; BSTR host = str.AllocSysString(); long port = 3246; m_dvt.Connect(&host,&port); The function fails! How I should pass the parameter:confused:
-
Winsock and MFCMay be the download stuff itself got some bugs in !!! May I know what you trying to do?
-
RealTime Priority?hi thanks for you idea, i did a google search with the string "Real Time plug in for NT" but i couldn't come across any windows compatible plug in's. would you please refer me one :rolleyes:
-
RealTime Priority?Hi Ant, my application is time sensitive. even mouse move will affect its normal operation. This is why i have to suspend other programs when my exe run a thread. Actually i found a standalone program in the net that list out all the running programs (I give you the link asap). When i set the priority to real time (24). I found my program running fine while i cant even access the mouse. But i want to do this programmatically.
-
RealTime Priority?I tried...but it doesn't work. I am in VC6. Does this stuffs work under VC6? In the loader program i am using the below code, STARTUPINFO suInfo; PROCESS_INFORMATION procInfo; CString m_Process; m_Process.Format(_T("%s\\my.exe"),curDir); memset (&suInfo, 0, sizeof(suInfo)); suInfo.cb = sizeof(suInfo); ::CreateProcess(m_Process, NULL, // can also be NULL NULL, NULL, FALSE, REALTIME_PRIORITY_CLASS, NULL, NULL, &suInfo, &procInfo); if (procInfo.dwThreadId == NULL) { AfxMessageBox("nope"); } else { ::SetThreadPriority(&procInfo.dwThreadId,THREAD_PRIORITY_HIGHEST); } When I check in process viewer the class priority is "Very High", the thread priority remain "normal". Also when a thread runs in "my.exe" it's not given the highest priorities, i am free to access other programs.
-
RealTime Priority?I wanna set real time priority to my application. At first a loader program runs myapp. Then I want to get the process id using exe name. With exe name i must be able to set its priority to REALTIME. My concept may sound correct but i dont know how to program it. Anybody can help me;P
-
PriorityMy application is CPU time sensitive. When it runs i want to suspend all other applications including mouse & keyboard. I know SetThreadPriority got something to do with this. But I dont know how to use it. Anyone can help me ;P
-
How to get characters just deleted by BackSpace key(or Delete key)May be this one helps you... BOOL CParentWnd::PreTranslateMessage(MSG* pMsg) { if (pMsg->message == WM_KEYDOWN) { if(pMsg->hwnd == urCtrl.GetSafeHwnd()) { switch (pMsg->wParam ) { case VK_BACK_SPACE : {//TRY HERE} } } }
-
How to get characters just deleted by BackSpace key(or Delete key)I understand you are editing in an edit control which you expect to UNDO when you delete a character. Am I correct? If so use CEdit Clipboard Operations.;)
-
getline in richedit...Hi, I am using CRichEditCtrl to edit Unicode characters like Arabic, Chinese and Japanese. When I tried to get the Unicode values of the characters typed in as below I can able to get only the lower 2 bytes not the whole 4 bytes. UINT nChar = 0x0000; int nLineLength,nRead; CString strLine; for(int i = 0; i < m_cRich.GetLineCount(); i++) { nLineLength = m_cRich.LineLength(m_cRich.LineIndex(i)); nRead = m_cRich.GetLine(i,strLine.GetBuffer(nLineLength + 3), nLineLength + 1); strLine.ReleaseBuffer(nRead); for(int j=0;j
-
editing unicode char ?yes... i have done it already... but if i copy/paste those arabic or chinese text to a windows standard edit control it only shows junks ("?_?") not the real text... :mad:
-
editing unicode char ?Anybody know how to type unicode characters like arabic, chinese, korean etc directly into an edit box. I am using windows XP with unicode languages support. I want to paste the unicode text i copied from character map to an edit conrol. But the edit control show junk. :rolleyes:
-
Type Conversion ?Yep... I found it...its char str[][7] = {"123456", "789012", }; USES_CONVERSION; int val = lstrlen(A2W(str[0])); :)
-
Type Conversion ?Yep... it works... In the following... char str[][7] = {"123456", "789012", }; lstrlen(str[0]); under unicode build throws error C2664: 'lstrlenW' : cannot convert parameter 1 from 'char [7]' to 'const unsigned short *' How to handle this? :rolleyes: