Sign in to follow this  
Followers 0
PERTU

Input Box cancel button

3 posts in this topic

Hi,

I have an InputBox, and I want the script to exit if the cancel button is pressed.

Here is the code for my InputBox:

$scene = StringRight("00" & (InputBox("MoveRenderset", "Quel scène?", $defscene , "")),3)oÝ÷ Økçm+ºØ­ßÛ'¢Ü(®H§ay"¶·­º¹ì¶®º+¡ô­®)àF(!µ«­¢+ØÀÌØí͹ôMÑÉ¥¹I¥¡Ð ÅÕ½ÐìÀÀÅÕ½ÐìµÀì¡%¹ÁÕÑ ½à ÅÕ½Ðí5½ÙI¹ÉÍÐÅÕ½Ðì°ÅÕ½ÐíEÕ°Í¡¹üÅÕ½Ðì°ÀÌØí͹°ÅÕ½ÐìÅÕ½Ð줤°Ì¤)%ÉɽÈôÄQ¡¸(á¥Ð)¹%

Anybody knows how to do it?

Thanks,

Olivier.

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

Because the last function being called there is StringRight() which isn't failing.

$scene = InputBox("MoveRenderset", "Quel scène?", $defscene , "")
If @error Then Exit
$scene = "00" &  StringRight($scene, 3)

Edited by SmOke_N

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Share this post


Link to post
Share on other sites

Because the last function being called there is StringRight() which isn't failing.

$scene = InputBox("MoveRenderset", "Quel scène?", $defscene , "")
If @error Then Exit
$scene = "00" &  StringRight($scene, 3)
Thank you, It works like I wanted. I should'nt hesitate to use the same variable more often.

Olivier.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0