Here's my answer, but it's based on me only knowing one way to "read" a user input - the M291 command. Someone else might have a better method.
M291 posts a message and the user has two response options, "OK" and "Cancel". According to the M291 wiki page, if the users responds "OK", execution continues, but if they respond "Cancel", it "cancels the operation in progress".
I use the M291 in the following way:
global response = "Cancel" ;set the variable to the default Value.
M291 P"To keep the default, select "Cancel" R"To change the default to the new value, select OK" S3 ; use the box title and the message to describe the two options.
set global. response = "OK"
I put these lines in their own macro. If the user responds OK, the last line is executed and the global variable becomes the OK value. If they select Cancel, the macro exits without executing the last mine and the "Cancel value is used.
Someone may know better what "operation in progress" means and maybe this could be written in an if statement in the code.
A good FW wishlist item would be new M291 parameters to specify the words on the buttons, and have the response stored in the object model so you could read the response directly.