Connexion rapide:  

Forum: General Discussion

Sujet VDJ Script: How to send key events or to run a command
Hi Everybody,

I was wondering if it is possible to send key events using VDJ script. I want to do something like mapping the Pads to send "Ctrl+1"key event for example, which is a shortcut to another application (in my case OBS to switch scenes).

The second question is: Can you send commands to Windows to start another programs using VDJ script?

THX in advance
 

Posté Sun 17 May 20 @ 8:43 am
No. It's not possible to launch secondary applications from within Virtual DJ using script.
 

Posté Sun 17 May 20 @ 12:13 pm
locoDogPRO InfinityModeratorMember since 2013
OBS has it's own programmable shortcut keys. I linked "pg dn" to start/stop recording I haven't tried any others as I only use OBS for screen recording of vdj interface for demo videos, for actual performance I record with vdj.

As for opening other programs, can be done with a plugin, I made RayPitman [top bloke] a little plugin that opened notepad for his song notes. If you use windows send me a pm if you want something made.
 

Posté Sun 17 May 20 @ 2:34 pm
Hi locodog and thanks for the help,

opening other programs from VDJ is not my main problem.
What I want to do is the following:
* In OBS I have like 3 scenes.
* I map every scene selection with a hotkey in OBS. (Like CTRL+1, CTRL+2 etc.)
* Instead of pressing keys on my keyboard I want VDJ to send the key event CTRL+1 when I press a Pad button, so I do not need to have the keyboard around.

But this is not a too big issue. I can use the keyboard, too.
I thought maybe there was a script verb I missed, which could do the job.

Greetings from Germany
 

Posté Mon 18 May 20 @ 8:49 pm
locoDogPRO InfinityModeratorMember since 2013
fair enough I think I'm going to try make something anyway that sends F13-24 key strokes, just to see if I can do it, it might come in useful at some point
 

Posté Mon 18 May 20 @ 9:58 pm
 

Posté Mon 18 May 20 @ 9:59 pm
Could also use MidiToKey possibly to take direct inputs from your controller, and "map" it to do keyboard key inputs..
https://obsproject.com/forum/resources/midikey2key-translates-midi-events-to-key-shortcuts.590/

Not tested myself, but might require the OBS program to be active window for it to "hear" any keyboard strokes, much as you probably will with your regular keyboard as well (they only work if the program is the active window)


(probably much easier to hit the Tab key (or Win+Alt+Tab) to switch between VDJ and OBS though, and simply do the CTRL 1 scene directly ;-) )
 

Posté Mon 18 May 20 @ 10:11 pm
locoDogPRO InfinityModeratorMember since 2013
Rune (dj-in-norway) wrote :
...require the OBS program to be active window for it to "hear" any keyboard strokes, much as you probably will with your regular keyboard as well (they only work if the program is the active window)


not the case, OBS can be in the background

 

Posté Mon 18 May 20 @ 10:21 pm
locoDogPRO InfinityModeratorMember since 2013
locodog wrote :
I'm going to try make something anyway that sends F13-24 key strokes, just to see if I can do it, it might come in useful at some point


I made it, well I have my launchpad calling "F13" & "Shift+F13" and OBS sees it.
so more keys will be easy.
If anyone is interested speak up.

side note, might be some power user applications with this one too.
 

Posté Wed 13 Oct 21 @ 6:10 pm
Hey Locodoc,
I'm interested on how to use this feature. Is it kind of plugin you programmed or how does it work?
Cheers
Jochen
 

Posté Sat 20 Nov 21 @ 11:49 am
locoDogPRO InfinityModeratorMember since 2013
a plugin and a padpage, my device talks to pads, pads talk to my plugin and plugin sends keystrokes which obs will recognise, in this video, to prove the concept I had to use mouse [and to sort of prove I wasn't using a keyboard with a F13 key], so added a slight delay between pad press and keystroke send, for real use this delay can be turned off.


send me a pm if interested.
 

Posté Sat 20 Nov 21 @ 3:18 pm
Locodog, did you end up creating a std plugin that can call external apps? Like a bat/command file?
I seem to remember something like that...
 

Posté Sun 12 Mar 23 @ 1:57 pm
locoDogPRO InfinityModeratorMember since 2013
I did, I'll look for it.
EDIT I've found one of them, is call by
set_var_dialog ok? [type the name of path of the thing you want to open] or do you want a select file dialog
 

Posté Sun 12 Mar 23 @ 2:03 pm
locoDogPRO InfinityModeratorMember since 2013
Edit, I think I'm talking to the guy now. [whiteweddingdj]

Edit2 And I think he's happy - one plugin to run his .bat file. another plugin to shutdown his machine.
 

Posté Sun 12 Mar 23 @ 3:12 pm
locodog wrote :
Edit, I think I'm talking to the guy now. [whiteweddingdj]

Edit2 And I think he's happy - one plugin to run his .bat file. another plugin to shutdown his machine.


Cool :)
 

Posté Sun 12 Mar 23 @ 7:37 pm