Hey all again,
Well I’ve been away so long that I’ve kinda forgotten how to use LUA/Ctrlr and could use some help again.
I want to call a method when I change tabs.
When I click on
Tab 0,
I want to send Midi Msg “Control Change #95/Value “1”.
Tab 1,
I want to send Midi Msg “Control Change #95/Value “127”.
Tab 2,
I want to send Midi Msg “Control Change #95/Value “2”.
I assume I need to use code like,
— Called when the current tab in an uiTabs component is changed
—
currentTabChanged = function(modulator,currentTabIndex)
console (string.format (“currentTabChanged tabIndex=%d”, currentTabIndex))
l = getComponent(“label-current-tab”)
if l ~= nil then
l:setPropertyString (“uiLabelText”, string.format (“Current tab=%d”, currentTabIndex))
end
end
and somehow put code like this in it..
selectTimber1 = {0xB0; 0x5F, 0x01}
panel:sendMidiMessageNow(CtrlrMidiMessage(selectTimber1))
but I havent messed with code for so long that I am lost in how to do this 🙁
can anyone help me get this to work. I’m hoping it’s very simple and all I need is a push in the right direction to get it to work..
Thanks!
-
This topic was modified 7 years, 9 months ago by Synthetech.
-
This topic was modified 7 years, 9 months ago by Synthetech.