Welcome to the new and improved Native Instruments online community. Join our active forum of 40,000+ members for discussions and much more.
Multiple Load/Save Buttons

Andrew Finch
Member Posts: 17 Member
Hi all,
I am working on a project that requires multiple (separate) load/save buttons for different controls on a GUI. So far I have worked this out:
on init declare $count declare ui_button $Load declare ui_button $Savea declare %preset[2] declare const $MAIN_PAGE := 2 declare %main_view_id[$MAIN_PAGE] declare $load_arr_id $load_arr_id := -1 declare $save_arr_id $save_arr_id := -1 declare ui_slider $knob (0,1000000) declare ui_slider $knob2 (0,1000000) make_persistent ($knob) end on on ui_control ($knob) %preset[0] := $knob end on on ui_control ($knob2) %preset[1] := $knob2 end on on ui_control ($Load) $load_arr_id := load_array(%preset,0) end on on ui_control ($Save) $save_arr_id := save_array(%preset,0) end on on async_complete if ($NI_ASYNC_ID = $load_arr_id) $load_arr_id := -1 $Load := 0 if ($NI_ASYNC_EXIT_STATUS = 1) $knob := %preset[0] $knob2 := %preset[1] end if end if if ($NI_ASYNC_ID = $save_arr_id) $save_arr_id := -1 $Save := 0 end if end on
At the moment this creates a load and save button for two sliders but I essentially want to incorporate another set of load/save buttons to independently load/save two more sliders, how do I go about adding this into the code I have worked out so far? Thanks in advance!
0
Comments
-
Should use multiple async ID variables then.
0
Back To Top
Categories
- 10.7K All Categories
- 22 Welcome
- 449 Hangout
- 59 NI News
- 209 Tech Talks
- 1.1K Native Access
- 4.9K Komplete
- 621 Komplete General
- 1.1K Komplete Kontrol
- 1.8K Kontakt
- 487 Reaktor
- 154 Battery 4
- 271 Guitar Rig & FX
- 202 Massive X & Synths
- 212 Other Software & Hardware
- 2.3K Maschine
- 14 Sampling Room
- 2.6K Traktor
- 2.4K Traktor Software & Hardware
- Check out everything you can do
- Create an account
- See member benefits
- Answer questions
- Ask the community
- See product news
- Connect with creators