Hello All
Here is a little piece of code which I would expect to change the value of combo box value and of the second button when first button is pressed… but it does not work… what am I doing wrong ? Thanks for help.
<Cabbage>
form caption("Untitled") size(800, 600), colour(58, 110, 182), pluginID("def1")
button bounds(24, 36, 80, 40) channel("buttonchan00") identchannel("setbuttonchan00") text("On", "Off")
groupbox bounds(148, 22, 200, 100) {
button bounds(10, 20, 80, 40) channel("b1") identchannel("setb1") value(1) text("Push me", "Pushed") colour:0(161, 47, 47, 255) colour:1(21, 161, 106, 255)
combobox bounds(10, 70, 80, 20) channel("combochan02") identchannel("setcombochan02") value(3) text("Item 1", "Item 2", "Item 3", "Item 4")
}
</Cabbage>
<CsoundSynthesizer>
<CsOptions>
-n -d -+rtmidi=NULL -M0 -m0d --midi-key-cps=4 --midi-velocity-amp=5
</CsOptions>
<CsInstruments>
; Initialize the global variables.
sr = 44100
ksmps = 32
nchnls = 2
0dbfs = 1
instr 1
if changed:k(chnget:k("buttonchan00"))==1 then
if chnget:k("buttonchan00")==1 then
chnset "value(0)","setb1"
chnset "value(2)","setcombochan02"
else
chnset "value(1)","setb1"
chnset " value(1)","setb1"
endif
endif
endin
</CsInstruments>
<CsScore>
;causes Csound to run for about 7000 years...
f0 z
i 1 0 3600
</CsScore>
</CsoundSynthesizer>