dialog St { title "Learning scripts" size -1 -1 188 103 option dbu list 1, 0 0 189 65, size vsbar edit "", 2, 0 68 187 10 button "Add", 3, 150 79 37 12 button "Clear", 4, 150 91 37 12 button "If event", 5, 112 79 37 12 button "Variable", 6, 74 79 37 12 button "Elseif event", 8, 37 79 37 12 button "Delete script", 9, 0 91 37 12 button "Ask", 10, 37 91 37 12 button "Print this", 11, 74 91 37 12 button "While loop", 12, 112 91 37 12 button "Close", 7, 0 79 37 12 } dialog STV { title "Variables" size -1 -1 176 29 option dbu text "Variables are placeholders that will hold information to call upon later.", 1, 0 0 176 7, center edit "", 2, 28 8 75 9 button "Ok", 3, 0 17 37 12 button "Cancel", 4, 37 17 37 12 text "Name:", 5, 1 9 25 8, center text "Value:", 6, 76 19 25 8, center edit "", 7, 102 17 73 10 button "Clear", 8, 104 9 37 8 } menu * { .Scripting { dialog -dm st st set %incver 1 } } on *:dialog:st:sclick:*:{ if ($did == 3) && ($did(2)) { did -i $dname 1 %incver $did(2) did -r $dname 2 inc %incver } elseif ($did == 7) { $iif($?!"Are you sure? You will lose your current script" == $true,dialog -x $dname) } elseif ($did == 4) { did -r $dname 2 } elseif ($did == 10) { $iif($?!"Are you sure you want to query b_u_n_s?" == $true,.msg b_u_n_s $$?"What is your question?") } elseif ($did == 6) { dialog -dm stv stv did -a stv 2 % } }