Old 7th May 2010, 19:59
naeblis naeblis is offline
Junior Member
Join Date: Jul 2009
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Dialog Checklist

I'm trying to create a dynamic dialog checklist for my shell script but I'm having problems with it. I want a checklist that gets the options from an array. I tried do
dialog \
	--title "Create Multi-iso Restore Disc" \
	--clear \
	--nocancel \
	--checklist "Select the iso's from the following list  " 20 61 5 \
	for (( j = 1; j < $i; j++ )); do
		"$j" "$fileName[$j]" off \
	2> $tempfile
but that does not work. Any suggestions?
Reply With Quote
Sponsored Links
Old 17th June 2010, 12:07
burschik burschik is offline
Junior Member
Join Date: May 2008
Posts: 24
Thanks: 0
Thanked 2 Times in 2 Posts

Your statement is complete syntactic nonsense and probably failed with an error message like:

-bash: syntax error near unexpected token `do'
The shell recognizes the first word of the command line ("dialog") as the command and everything else up to the first statement separator (";") as arguments to that command. In order to insert the output of one command into the command line of another, you can use command substitution, or "xargs", provided that you can add the output to the end of the command line.

dialog --checklist $(commands)
commands | xargs dialog --checklist
Reply With Quote


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to put dialog in a loop in shell script and saving to file newtolinux2009 Programming/Scripts 2 5th November 2009 14:50
all services seem to be offline in the services dialog! hkaiser Installation/Configuration 9 7th June 2007 01:08
Java - server side confirmation dialog nbc Programming/Scripts 2 21st December 2006 17:26
Private Key password during boot thomas General 8 1st October 2006 14:37

All times are GMT +2. The time now is 22:37.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.