Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
boo_zmud
Newbie


Joined: 05 Sep 2003
Posts: 5
Location: United Kingdom

PostPosted: Tue Sep 16, 2003 11:00 am   

Prompt cancellation
 
Quick question:

It's likely I'm doing something wrong, but the #prompt and %prompt command/functions don't seem to 'cancel' even though the cancel button is clicked.

For example:

tmpTarget = %prompt (@tmptarget, "Name the target.")

If the user presses OK the tmpTarget var is populated, if they press Cancel the same applies, therefore there is no test to perform to indicate the user has pressed cancel.

And ideas?

TIA
Reply with quote
LightBulb
MASTER


Joined: 28 Nov 2000
Posts: 4817
Location: USA

PostPosted: Tue Sep 16, 2003 6:14 pm   
 
The first line is without a default value, the second uses the current value of the variable. They both clear the variable if Cancelled.
#VAR tmpTarget %prompt( , Name the target.)
#VAR tmpTarget %prompt( @tmpTarget, Name the target.)

You have a space between %prompt and (@tmptarget, "Name the target."). It doesn't belong there.
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD General Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net