Click here to Skip to main content
15,920,503 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I want to know can I control another form in another application ?
like the textBox in other application or the button.
Can I ???
Posted
Updated 3-Sep-10 22:34pm
v2
Comments
Mohammed K.M 4-Sep-10 6:00am    
I mean that I can send a string to textBox to another application.
ex: There is atextbox "username" and textbox "password" in my application I can send the username and password
to that application .
Can I??

No, as such you cannot. There would be security and other issues.
 
Share this answer
 
What exactly do you mean by "control"? If both applications are yours, then you can send messages between them to communicate and take action appropriately. But I don't see any advantage on doing it. In fact it is will be the opposite.

If the applications are not yours, You can instrument and send windows messages, but that is completely different story.

So, in short, better Not.
 
Share this answer
 
v2
Yes you can but it can get nasty.
Every control in a windows system has a handle. You need to find the handle for the control you want access to.
Once you have the handle you can use SendMessage[^] to send whatever you need.
 
Share this answer
 

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