PopUp Menu Default

Hello Friends,
I have a PopUp menu with 7 items with the first item being “Select Print Menu” which is a dummy line item letting the operator know there is a list. My question is how can I get it to return to that state, “Select Print Menu” after the menu item is completed. Right now it returns the name of the item selected. I would like it to default every time to “Select Print Menu”.

After you are done with the linked variable containing the selection just reset it to “Select Print Menu” and use showvariables along with the variable name to re-display it in the popup menu. This covered in the Help file under Popup Menu Button Object.

Sorry, I am just not getting it. I have tried following the directions in the help file but no matter where I put the showvariable statement in I get “unknown statement:showvariable”.
I have the PopUp menu set to go to a procedure with case statements that select the item and call the procedure.

Say the variable containing the pop up selection is theSel, after you have processed the users selection do this:

theSel="Select Print Menu"
showvariables theSel

Thanks Bill,
I finally got it right. The reason I was getting the error is both Gary and the help file gave me the wrong information. Both of them said “showvariable” it was missing the plural “s” at the end. I did not notice it until I saw your response. I hope someone tells Jim the help file needs to be corrected.
Thanks again. I appreciate it.

1 Like

You are correct about the Help file using the singular but I definitely had it right for a change.:innocent:

You may have missed the detail that the statement is called showvariables, in other words, it is plural even if you are only updating one variable.

Oh, I see Bill has already supplied a correct example :slight_smile:

I’ve posted a correction to the Help file entry.