Click here to Skip to main content
16,004,806 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: get msn conversation window elements Pin
smargada18-Oct-05 4:32
smargada18-Oct-05 4:32 
GeneralRe: get msn conversation window elements Pin
ThatsAlok18-Oct-05 4:38
ThatsAlok18-Oct-05 4:38 
QuestionNeed to detect logged in users - NOT using GetUserName/Ex Pin
Xori17-Oct-05 7:11
Xori17-Oct-05 7:11 
AnswerRe: Need to detect logged in users - NOT using GetUserName/Ex Pin
David Crow17-Oct-05 7:34
David Crow17-Oct-05 7:34 
GeneralRe: Need to detect logged in users - NOT using GetUserName/Ex Pin
Xori17-Oct-05 7:47
Xori17-Oct-05 7:47 
QuestionRe: Need to detect logged in users - NOT using GetUserName/Ex Pin
David Crow17-Oct-05 8:18
David Crow17-Oct-05 8:18 
GeneralRe: Need to detect logged in users - NOT using GetUserName/Ex Pin
ThatsAlok17-Oct-05 18:15
ThatsAlok17-Oct-05 18:15 
Questionkeybd_event() in explorer/firefox/ie and the like Pin
dr_illbatting17-Oct-05 7:05
dr_illbatting17-Oct-05 7:05 
Hi,
I've written a snipplet (application B) that sends keystrokes to a application A when i press a button in application B.

My application (B) gets focus.

i reset focus with SetActiveWindow(NULL), which effectively resets the focus to the last application that was active/focused.

I send a keystroke:

keybd_event(VkKeyScan('a'), 0, 0, 0);<br />
keybd_event(VkKeyScan('a'), 0, KEYEVENTF_KEYUP, 0);


so, the "a" is effectively sent to the application. A problem however is applications that automatically select all text in a window(widget) when they get focus.. explorer for example has this "feature". If i want to enter the location: "aaa":

1) Explorers locationbar is active.

2) I press the button to send the "a". My app gets focus, recents focus and sends the keystroke.

3) Explorer receives the "a".

4) When i want the second "a" Explorer looses focus for an instant. When i set the focus back to it it automatically selects the "a" i previously wrote, and in turn makes my app overwrite it.

etc.

Is there any way i could prevent my application from getting focus at all when i click on it?

Thanks in advance!

-- modified at 13:05 Monday 17th October, 2005
AnswerRe: keybd_event() in explorer/firefox/ie and the like Pin
Anonymous17-Oct-05 20:11
Anonymous17-Oct-05 20:11 
QuestionHow to get the right URL before navigating the web page in the CHtmlView? Pin
superhandwolf17-Oct-05 5:52
superhandwolf17-Oct-05 5:52 
Questionstatic control colouring Pin
FarPointer17-Oct-05 5:51
FarPointer17-Oct-05 5:51 
AnswerRe: static control colouring Pin
David Crow17-Oct-05 7:27
David Crow17-Oct-05 7:27 
QuestionEarly Binding Pin
itkid17-Oct-05 5:36
itkid17-Oct-05 5:36 
QuestionQuestion on folder security permissions Pin
shiva e balasubramaniam17-Oct-05 4:44
shiva e balasubramaniam17-Oct-05 4:44 
QuestionClass Construction Problem Pin
bugDanny17-Oct-05 4:39
bugDanny17-Oct-05 4:39 
AnswerRe: Class Construction Problem Pin
toxcct17-Oct-05 4:50
toxcct17-Oct-05 4:50 
AnswerRe: Class Construction Problem Pin
Cedric Moonen17-Oct-05 4:54
Cedric Moonen17-Oct-05 4:54 
GeneralRe: Class Construction Problem Pin
bugDanny17-Oct-05 4:58
bugDanny17-Oct-05 4:58 
QuestionCMSFlexgrid \ Dialog problem Pin
69 Bay17-Oct-05 4:08
69 Bay17-Oct-05 4:08 
AnswerRe: CMSFlexgrid \ Dialog problem Pin
Cedric Moonen17-Oct-05 4:29
Cedric Moonen17-Oct-05 4:29 
GeneralRe: CMSFlexgrid \ Dialog problem Pin
69 Bay17-Oct-05 5:27
69 Bay17-Oct-05 5:27 
Question_gcvt() format? Pin
george ivanov17-Oct-05 3:43
george ivanov17-Oct-05 3:43 
AnswerRe: _gcvt() format? Pin
toxcct17-Oct-05 3:46
toxcct17-Oct-05 3:46 
QuestionRe: _gcvt() format? Pin
David Crow17-Oct-05 4:29
David Crow17-Oct-05 4:29 
AnswerRe: _gcvt() format? Pin
toxcct17-Oct-05 4:46
toxcct17-Oct-05 4:46 

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.