Opening and closing windows via Bome in windows 10

I'm on bome miditranslator V1.8.0 build 757

With v1.6 or 1.7 I used to be able to create a button on a midicontroller that would open and close specific windows on my windows computer, like "C:\Program Files", using a translator in bome, using the same button, going from "xx yy 7F" to "xx yy 00" (midi value going from 127 to 0), and the use of another translator using WM_messages.

This way I was able to open and close (multiple) window with one button(s). I was using 192 of these buttons in lemur to open specific applications, and/or open/close sets of folders and/or websites in one click, but sadly this is not working anymore the way it should as I am no loger able to close the windows on button up..

Now I know WM messages are no longer supported. But "execute file"+ "C:\Program Files"still works (for example). Is there a command for "close window C:\Program Files" that I can ad to a translator that would replace the WM command I was using before?

 

Kind regards, Jurgen

Hi, Jurgen,

It looks like you are running Bome MIDI Translator  Classic. You can send keystrokes and MIDI messages only. If you have a helper application that can take these keystrokes and change them into either command line output, or use Bome MIDI Translator Pro which can do command lines natively.

Actually, keystrokes, mouse movement and mouse clicks are WM messages and Bome MIDI Translator Pro version supports all of these, however not more complex WM messages like Close Window. Kill application etc.

For that you would aso need a helper application that translates what Bome MIDI Translator sends into the WM Actions you want.  I typically do this in programs like AutoHotKey.  I can set AutoHotKey to either:

1) Monitor for keystrokes, mouse actions etc

2) Monitor for MIDI messages (with some help from script available on their user forum

And with either of the above, set up the script to do more complex outgoing actions.

This is beyond the scope of Bome Free support but if you have a specific thing in mind, you can reach out to me via email for paid services.

Steve Caldwell
Bome Customer Care


Also available for paid consulting services: bome@sniz.biz

 

Thanks, I\'m on Pro, but as you explained I would still need autohotkey scripts to close specific windows the way I was able to do in the older bome versions. The reason I asked is: I have everything I need already setup in Lemur: 192 named buttons sending midi notes. I also have a bome template that used to work (build with an older bome version). But I cannot use this older version of bome on windows 10. I guess I need to re-program everything in autohotkey, since I do not want to use two different applications for actions on the same button/midi note, it would get very messy to keep track of everything.. (this would be: bome for opening, and autohotkey for closing windows as indicated in your answer). I was just looking for a way to avoid this, but as I understand it\'s not possible anymore.

I already tried your solution in the past, but I never got the midi-part of autohotkey to work properly. I guess I need to have a look at it again...

Thanks for your quick answer Steve!

 

 

I'm not aware of any Bome Version that provided this functionality. Pro or Classic. Are you sure you weren't using some version of 3rd party software using MT Player instead. Maybe they enhanced their version for more capabilities.

 

I see this feature was removed in version 1.8.0 (before my time with Bome).

 

History

 

https://www.bome.com/products/miditranslator/overview/version-history

No I,m 100% shure I used just bome for this. I could send you the file. For now an example: These scripts (a part of a larger file) used to open (on value 7F) AND CLOSE (on value 00) the "my computer" window and the "program files" folder:

 

[Preset.30]
Name=WINDOWS control
Active=1
PresetSwitchIgnore=1
Name0=Q6 computer
Incoming0=MID2MIDA00020015In From MIDI Yoke: 130010loopMIDI Port 13B7007F
Outgoing0=ExF10017C:\WINDOWS\explorer.exe0003/e,
Options0=Actv01Stop00OutO00
Name1=Q6 computer
Incoming1=MID2MIDA00020015In From MIDI Yoke: 130010loopMIDI Port 13B70000
Outgoing1=ExF10017C:\WINDOWS\explorer.exe0003/e,
Options1=Actv00Stop00OutO00
Name2=prog folder
Incoming2=MID2MIDA00020015In From MIDI Yoke: 130010loopMIDI Port 13B7017F
Outgoing2=ExF10010C:\Program Files0000
Options2=Actv01Stop00OutO00
Name3=prog folder
Incoming3=MID2MIDA00020015In From MIDI Yoke: 130010loopMIDI Port 13B70100
Outgoing3=SMsg|D16|W0|L0|TTWnd050010C:\Program Files0000
Options3=Actv01Stop00OutO00

Thanks for your answer:

"I see this feature was removed in version 1.8.0 (before my time with Bome)".

Now I understand your previous answer, ignore my last post please as it is irrelevant anyway.

 

kind regards, Jurgen

 

Does anyone know why this feature was removed, and if there is any chance of it returning? It would be very useful to me to be able to close windows and specific programs with MIDI Translator Pro.

Hi, the old Bome MT Pro had a very low level function to send a Window Message (WM_) on Windows (only). With clever programming, that could be used to close a program. We’ve removed because it was so difficult to set up and I wasn’t aware of any user actually using it…

Anyway, with the current version of MIDI Translator Pro, you have a number of possibilities to close a window:

  • Use Outgoing Keystroke Action to send keystroke Alt-F4 or Ctrl+F4 using injection. Internally, injection uses WM_ messages, so this is very similar to what could have been done with the old ‘send WM’ outgoing action.
  • Use Outgoing Application Focus action to activate the window/program to close, followed by outgoing Keystroke action to send regular keystrokes to close it (again, Alt-F4 or Ctrl-F4). This works with MT Pro on MacOS, too (though may need to adapt the keystroke to Cmd-Q or so).
  • on MacOS, you can also use the Outgoing AppleScript Action to execute a small script to close a particular window.

I hope that helps!
Thanks,
Florian

1 Like

Sorry Florian, I only just saw that you responded to my question. Thanks for this! I think using Application Focus plus the close keystroke action is exactly what I needed. Much appreciated!