Click here to Skip to main content
15,914,111 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralEdit Box from funtion Pin
W00dSt0ck20-Sep-04 2:14
W00dSt0ck20-Sep-04 2:14 
GeneralRe: Edit Box from funtion Pin
Alpha Siera20-Sep-04 3:00
Alpha Siera20-Sep-04 3:00 
GeneralRe: Edit Box from funtion Pin
W00dSt0ck20-Sep-04 3:18
W00dSt0ck20-Sep-04 3:18 
GeneralRe: Edit Box from funtion Pin
Alpha Siera20-Sep-04 3:31
Alpha Siera20-Sep-04 3:31 
GeneralRe: Edit Box from funtion Pin
Arsalan Malik20-Sep-04 3:08
Arsalan Malik20-Sep-04 3:08 
GeneralRe: Edit Box from funtion Pin
W00dSt0ck20-Sep-04 4:10
W00dSt0ck20-Sep-04 4:10 
GeneralRe: Edit Box from funtion Pin
David Crow20-Sep-04 5:36
David Crow20-Sep-04 5:36 
Generalglobal hotkey: i dont get the WM_HOTKEY message Pin
Member 134487420-Sep-04 2:00
Member 134487420-Sep-04 2:00 
I have a volume control prog. downloaded and written the necessary hotkey code lines based on

Beginner's Tutorial - Using global hotkeys
http://www.codeproject.com/system/nishhotkeys01.asp
into it.

The hotkey succesfully registers.
RegisterHotKey(this->m_hWnd, myatom, MOD_CONTROL, VK_UP)
on querying this line I get a true

in the header:
public:
...
LRESULT OnHotKey(WPARAM wParam, LPARAM lParam);
...
DECLARE_MESSAGE_MAP()


in the correspondig cpp file:
BEGIN_MESSAGE_MAP(CVolumeControlDemoDlg, CDialog)
//{{AFX_MSG_MAP(CVolumeControlDemoDlg)
... // some more messages
ON_MESSAGE(WM_HOTKEY,OnHotKey)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()


and also in the cpp file:
LRESULT CVolumeControlDemoDlg::OnHotKey(WPARAM wParam, LPARAM lParam)
{
if(wParam == MOD_CONTROL && lParam == VK_UP) {
log.write("!!! HOTKEY PRESSED SUCCESS !!!");
}
return 0;
}

on pressing the hotkey while the prog is running -> NOTHING happens. But if I call the following line in the code I get the WM_HOTKEY message correctly:
SendMessage(WM_HOTKEY, MOD_CONTROL, VK_UP);

What am I doing wrong? Plz in very easy language since I am a programming N00b. TY
GeneralInternetGetConnectedState and LAN Pin
WernerP20-Sep-04 1:05
WernerP20-Sep-04 1:05 
QuestionHow to lock a CFile in VC++ 6.0? Pin
Neeranjan19-Sep-04 22:26
Neeranjan19-Sep-04 22:26 
AnswerRe: How to lock a CFile in VC++ 6.0? Pin
Alpha Siera19-Sep-04 22:40
Alpha Siera19-Sep-04 22:40 
GeneralRe: How to lock a CFile in VC++ 6.0? Pin
Neeranjan19-Sep-04 22:59
Neeranjan19-Sep-04 22:59 
GeneralRe: How to lock a CFile in VC++ 6.0? Pin
Alpha Siera20-Sep-04 0:22
Alpha Siera20-Sep-04 0:22 
GeneralRe: How to lock a CFile in VC++ 6.0? Pin
David Crow20-Sep-04 5:43
David Crow20-Sep-04 5:43 
GeneralRe: How to lock a CFile in VC++ 6.0? Pin
Neeranjan20-Sep-04 20:22
Neeranjan20-Sep-04 20:22 
GeneralRe: How to lock a CFile in VC++ 6.0? Pin
David Crow21-Sep-04 3:40
David Crow21-Sep-04 3:40 
GeneralRe: How to lock a CFile in VC++ 6.0? Pin
Neeranjan21-Sep-04 4:38
Neeranjan21-Sep-04 4:38 
GeneralRe: How to lock a CFile in VC++ 6.0? Pin
David Crow21-Sep-04 5:24
David Crow21-Sep-04 5:24 
GeneralRe: How to lock a CFile in VC++ 6.0? Pin
Neeranjan21-Sep-04 20:37
Neeranjan21-Sep-04 20:37 
GeneralRe: How to lock a CFile in VC++ 6.0? Pin
David Crow22-Sep-04 5:02
David Crow22-Sep-04 5:02 
GeneralRe: How to lock a CFile in VC++ 6.0? Pin
Neeranjan22-Sep-04 18:40
Neeranjan22-Sep-04 18:40 
GeneralRe: How to lock a CFile in VC++ 6.0? Pin
David Crow23-Sep-04 2:50
David Crow23-Sep-04 2:50 
GeneralCalling C# web service from c++/MFC Pin
fajlerköaölgja19-Sep-04 22:09
fajlerköaölgja19-Sep-04 22:09 
Generalstupid question Pin
eli1502197919-Sep-04 21:49
eli1502197919-Sep-04 21:49 
GeneralRe: stupid question Pin
fajlerköaölgja19-Sep-04 22:33
fajlerköaölgja19-Sep-04 22:33 

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.