|
-
October 22nd, 2007, 11:50 PM
#1
How to set active an other application?
Hi friends,
I trying to develop a tool (the same On-screen Keyboard on Windows, but it's too small key button).
But i'm having a problem. When i click on the button on my application, how to set active other application to receive key code?
Can you help me?
Thanks
-
October 23rd, 2007, 02:59 AM
#2
Re: How to set active an other application?
That's not the way to create an on-screen keyboard. The idea is that your window doesn't get focus in the first place, so you never have to worry about setting it back to some other application. Check this out.
-
October 25th, 2007, 08:54 PM
#3
Re: How to set active an other application?
Hi Jmcilhinney,
Thanks for your solution.
But, when i run your code, it throw an exception (InvalidCastException) at m.Result = CType(NativeConstants.MA_NOACTIVATE, IntPtr). So, i replace it by m.Result = New IntPtr(NativeConstants.MA_NOACTIVATE), it ok.
Thanks so much.
Last edited by ntchinh; October 25th, 2007 at 08:56 PM.
-
October 25th, 2007, 10:19 PM
#4
Re: How to set active an other application?
Perhaps you're using .NET 1.x because that code is currently working in my .NET 2.0 app. There's evidence that you need to specify your version when posting.
-
October 26th, 2007, 12:56 AM
#5
Re: How to set active an other application?
ntchinh, have a look here
-
October 28th, 2007, 11:17 PM
#6
Re: How to set active an other application?
Yes, I think so.
Thanks about warned from you.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|