• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Foot switch stops when MS looses focus
#1
I have two monitors, MS running full screen on one and a virtual instrument on the other. I use two USB foot switches to change pages in MS, which works perfectly. Occasionally while I am playing I have to press a button on the instrument, which moves the focus to the instrument application, causing the foot switches to stop working. I've been trying to use a program called "AutoHotKey" to get the foot switches to work again. I tested it on Notepad and it works fine, but when I set it up for MS it does not work. I was wondering if anybody else has this problem or is there a better way to fix the problem.

Thanks for any help.


I finally got AutoHotKey working and here is what I ended up with:

****************
#NoEnv  ; Recommended for performance and compatibility with future AutoHotkey releases.
#Warn  ; Enable warnings to assist with detecting common errors.
SendMode Input  ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir%  ; Ensures a consistent starting directory.
DetectHiddenWindows, On ; Allow hidden windows to be visible by script
SetTitleMatchMode RegEx
^!l::    ;looks for CTRL+Alt+L
WinActivate, i)mobilesheets ;Set focus to mobilesheets
Send {Left}   ;Send right arrow
return
^!r::    ;Looks for CTRL+ALT+R
WinActivate, i)mobilesheets ;Set focus to mobilesheets
Send {Right}   ;Send right arrow
return
****************

I programmed one foot switch to send CNTRL+ALT+l and the other to send CNTRL+ALT_r. This program continuously looks for those codes to be sent and when it sees one it forces the focus to MS and then sends the Left or Right arrow commands to MS. So far no problems.
Reply


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


Users browsing this thread:
1 Guest(s)


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2019 MyBB Group.