451
Astrobasic / new command: popup
« on: December 16, 2020, 12:11:52 PM »
from the help:
[popup]
Syntax: popup(int x, int y, char options[$], label onclick, char default);
Action: present a popupmenu. If default >= 0 that entry will be selected.
Example:
[popup]
Syntax: popup(int x, int y, char options[$], label onclick, char default);
Action: present a popupmenu. If default >= 0 that entry will be selected.
Example:
Code: [Select]
window(666, 666);
char s[99];
int n;
button(0,0, "Test", test);
run;
:test;
popup(99, 99, "one|two|three", test1);
return;
:test1;
strset(s, "%d %d", n, menunumber);
setcaption(s);
n += 1;
return;