TinTin++ Mud Client The TinTin++ message board

 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
TinTin++ Mud Client

SYSTEM and return values

 
Post new topic   Reply to topic    The TinTin++ message board Forum Index -> Unix Shell
View previous topic :: View next topic  
Author Message
PowerGod



Joined: 04 Aug 2014
Posts: 339

PostPosted: Mon Aug 11, 2014 10:56 am    Post subject: SYSTEM and return values Reply with quote

Code:

#system echo -e "first\nsecond\nthird\n"| zenity --list --column=select


Is there a way to get a return value from this code directly ?

Or I have to write it on a file and then read it as the only solution ?
Back to top
View user's profile Send private message
moire



Joined: 29 Jan 2012
Posts: 24

PostPosted: Mon Aug 11, 2014 3:35 pm    Post subject: Reply with quote

You are probably looking for the #script command (see "#help script" in tt++):
Code:

#script {result} {echo "first\nsecond\nthird\n"| zenity --list --column=select}
#showme {You selected: $result[1].}
Back to top
View user's profile Send private message
PowerGod



Joined: 04 Aug 2014
Posts: 339

PostPosted: Mon Aug 11, 2014 6:57 pm    Post subject: Reply with quote

Cool !! this is working, thanks Smile

Code:

#script {selection} {echo -e "first\nsecond\nthird\n"| zenity --list --column=select}
#showme {You selected: $selection[1].}
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    The TinTin++ message board Forum Index -> Unix Shell All times are GMT - 5 Hours
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
Get TinTin++ Mud Client at SourceForge.net. Fast, secure and Free Open Source software downloads Get TinTin++ Mud Client at SourceForge.net. Fast, secure and Free Open Source software downloads
TinTin++ Homepage

Powered by phpBB © 2001, 2002 phpBB Group