Click here to Skip to main content
15,890,932 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I would like to know how to send message to other application through my application. For example i have opened notepad (but minimized) and my application and now i click "show it" and it shows notepad or if i type something in my application textbox then that it types in that notepad two even if its minimized!

Thank you! :)
Posted

1 solution

You need to SendMessage/PostMessage Windows messages to the target HWND. You may also need a CBT hook depending on how you want to manipulate the behavior of the destination window.

See this article on this topic:
Manipulating Windows using messages and simple CBT hooking[^]

(apparently lots of people are trying to do this nowadays, this question comes up very frequently).
 
Share this answer
 
v3
Comments
Espen Harlinn 20-Feb-11 19:19pm    
A 20 >> 2 - good answer, odd request, wonder why ...
Nish Nishant 20-Feb-11 19:20pm    
I agree, there's rarely a good reason to do this sort of thing :-)
FeRtoll 20-Feb-11 20:53pm    
when i do it to end ill share it with you :D Then you will see :P Its for fun and good use!
Does anyone of you have skype? i dont want to post 1000 questions. If anyone of you have add me "fertoll" i have only 2 more questions and its about process -> get proces by name and process -> child windows Thank you!

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900