NextPVR Forums
  • ______
  • Home
  • New Posts
  • Wiki
  • Members
  • Help
  • Search
  • Register
  • Login
  • Home
  • Wiki
  • Members
  • Help
  • Search
NextPVR Forums Public Developers v
« Previous 1 … 47 48 49 50 51 … 93 Next »
I need to check if a specific process has focus

 
  • 0 Vote(s) - 0 Average
I need to check if a specific process has focus
idkpmiller
Offline

Posting Freak

Posts: 817
Threads: 141
Joined: May 2006
#1
2007-01-04, 09:38 AM
Hi,

I have a problem I have struggled with for more than two days now and cannot seem to get around I am sure its possible I just have not worked it out yet :-(

I have an application that has been launched by the plugin and I can receive a key from a remote and translate that into a set of keys that need to be sent to the previously launched application. I use SetForeGroundWindow to send the launched application back to the front and then I have tried various methods to send the key sequence to the launched application. sendkeys doesnt seem to work at all.

However I have had some joy with SendInput; in that if I send the keys with the KeyDown and never do a KeyUP then the application receives them over and over.... :-(

I therefore believe it is a timing issue, I send the launched application to the foreground but I have no way (currently) of checking if it is there yet before I send my keys to it. I therefore am working on the premise that I require a way of checking if the launched application is the focused/foreground application, looping until it is and then sending my key sequence. I have tried GetForeGroundWindow but to be honest I got completly in a mucking fuddle.

Anybody got some help or a snip of code they could offer?

Thanks
idkpmiller
Offline

Posting Freak

Posts: 817
Threads: 141
Joined: May 2006
#2
2007-01-14, 10:44 AM
Has anyone out there got some idea of how this can be done I am still struggling with this.
I need a break through before I break down :-(
sub
Offline

Administrator

NextPVR HQ, New Zealand
Posts: 106,724
Threads: 767
Joined: Nov 2003
#3
2007-01-14, 03:38 PM
Sorry, its not something I've had to do. I'd be doing the same things that I'm sure you've been doing, ie off to google.
idkpmiller
Offline

Posting Freak

Posts: 817
Threads: 141
Joined: May 2006
#4
2007-01-15, 07:10 AM
Hey thanks for the reply Sub at least it makes me think that others also need google :-) Although this one is stumping me. I will prevail!! i hope ....
whurlston
Offline

Posting Freak

Posts: 7,885
Threads: 102
Joined: Nov 2006
#5
2007-01-15, 11:17 PM
http://www.vbcity.com/forums/topic.asp?tid=110524

Should help.
« Next Oldest | Next Newest »

Users browsing this thread: 1 Guest(s)



Possibly Related Threads…
Thread Author Replies Views Last Post
  Recording a specific episode based on season and episode number cbgifford 26 10,399 2014-12-19, 10:28 PM
Last Post: cbgifford
  Focus imilne 6 2,572 2011-07-16, 09:37 AM
Last Post: imilne
  Regaining focus McBainUK 2 1,699 2009-12-31, 04:31 PM
Last Post: McBainUK
  Set focus to list McBainUK 4 2,061 2009-12-09, 07:54 PM
Last Post: whurlston
  Finding focus of a control? bgowland 1 1,253 2008-02-02, 06:02 AM
Last Post: bgowland
  Set focus to another process? bgowland 2 1,489 2008-01-12, 03:18 AM
Last Post: bgowland
  Using getnamedimage and images of specific sizes pastro 4 1,914 2007-09-26, 03:10 AM
Last Post: pastro
  PostMessage() / IR32 No-Focus compatibility HydroChronic 1 1,571 2007-07-25, 06:36 PM
Last Post: sub
  Keeping GB-PVR in focus liteswap 6 2,337 2007-04-26, 04:07 PM
Last Post: pastro
  stopping the screensaver taking focus idkpmiller 2 1,562 2007-01-21, 12:43 AM
Last Post: idkpmiller

  • View a Printable Version
  • Subscribe to this thread
Forum Jump:

© Designed by D&D, modified by NextPVR - Powered by MyBB

Linear Mode
Threaded Mode