KiXforms Forum Index KiXforms
The Forum for the KiXforms Community
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
 Quick Links 
Site News
Downloads
Documentation
Donations
Script Archive
Tracking Systems

KiXforms not focused

 
Post new topic   Reply to topic    KiXforms Forum Index -> KiXforms.NET Discussion
View previous topic :: View next topic  
Author Message
Joe66
KiXforms Dabbler
KiXforms Dabbler


Joined: 25 Oct 2007
Posts: 7
Location: Kassel, Germany

PostPosted: Mon Apr 20, 2015 11:57 am    Post subject: KiXforms not focused Reply with quote

Hi,

I would like to create something like "onboardkeyboard" with KiXforms.
Task is, to have buttons with defined actions (i.e. Sendkeys).
Problem is: when I have an open application, for example notepad, and now want to klick on a button on KiXform which sends keystrokes, how can I make it happen in notepad? At the moment of "click the button", my form has the focus and notepad is in the backround.
So what I want is to let KiXforms start (the window is visible) but not beeing focused.

Can anyone help me?

Thanks in advance!
Back to top
View user's profile Send private message Send e-mail
enahsyemotp
KiXforms Regular
KiXforms Regular


Joined: 22 Sep 2010
Posts: 40
Location: Tulsa, OK

PostPosted: Tue Apr 21, 2015 12:03 am    Post subject: Reply with quote

Have you tried the built in kixtart function SetFocus()?

Usually you can do a SetFocus("test.txt - Notepad") or whatever the title of the notepad is. This will bring it to the foreground.
Back to top
View user's profile Send private message
Joe66
KiXforms Dabbler
KiXforms Dabbler


Joined: 25 Oct 2007
Posts: 7
Location: Kassel, Germany

PostPosted: Tue Apr 21, 2015 6:54 am    Post subject: Reply with quote

thanks for reply!
No that will not fit my request. I have defined a lot of complex commands and keycombinations with AutoHotkey. When I use different apps, my input comes mostly with mouse. And then I have to press Function keys for the Autohotkey-Commands. So the idea is, to have something like an onscreen keyboard which automatically inserts the selected things into my active application.
The active applications are more than one and differ in usage (web based, remote, local app). So the input of my KiXforms shall send the output to "the last app which was active before the click in KiXforms".

Any idea?
Back to top
View user's profile Send private message Send e-mail
enahsyemotp
KiXforms Regular
KiXforms Regular


Joined: 22 Sep 2010
Posts: 40
Location: Tulsa, OK

PostPosted: Tue Apr 21, 2015 5:14 pm    Post subject: Reply with quote

What happens if you send the keys Alt+Tab? Would it change to the last active window?
Back to top
View user's profile Send private message
enahsyemotp
KiXforms Regular
KiXforms Regular


Joined: 22 Sep 2010
Posts: 40
Location: Tulsa, OK

PostPosted: Tue Apr 21, 2015 5:17 pm    Post subject: Reply with quote

Or another option is to send the keys Alt+ESC. This rotates through open windows. Just a couple ideas.
Back to top
View user's profile Send private message
enahsyemotp
KiXforms Regular
KiXforms Regular


Joined: 22 Sep 2010
Posts: 40
Location: Tulsa, OK

PostPosted: Tue Apr 21, 2015 5:21 pm    Post subject: Reply with quote

Tested them both, the Alt+Tab does not seem to work as I would expect. But the Alt+Esc does. Give it a shot, unless I'm still not understanding the problem.

Code:
$nul = SendKeys("~{ESC}")
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    KiXforms Forum Index -> KiXforms.NET Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group