Reputation: 6567
I wan't to have a simple menu (main menu not menu bar) whith buttons to link to another form(s)/window(s)/caveses(s). Or atleast the code to switch bettween the screen.
What code (SQL/PL) would I put in the buttons or is there a better way to do this?
Upvotes: 1
Views: 4106
Reputation: 95
Why dont you just make 1 form only?1 form, many datablock,canvas, window
anyway, for your question, just call the block
go_block('your_block');
if you want to call another block
go_block('another_block');
hide_window('1st_open_window');
you should make 1 canvas in 1 window for better arrangement
Upvotes: 1
Reputation: 49
You can also use Stack canvas within the same form which gets visible as you click on the button.
SHOW_VIEW('CANVAS_NAME');
And in that stack you can do whatever you want.
Upvotes: 0
Reputation: 7932
That's a very broad question. If you want to show a specific window on WHEN-BUTTON-PRESSED
then you can use built in like below-
SET_WINDOW_PROPERTY('WINDOW_NAME', VISIBLE, PROPERTY_TRUE); --This would display the window
SET_WINDOW_PROPERTY('WINDOW_NAME', VISIBLE, PROPERTY_FALSE); --This will hide the window
The above would work if you use the SET_WINDOW_PROPERTY
within the same form.
In case you want to call another form from the parent form (which is the case as per your comment screenshot) you need to to use CALL_FORM
built-in like
CALL_FORM('MEMBERS');
Upvotes: 1