list of BooleanButtons will not display in hiCreateAppForm

D

David

Guest
The following snippet is used to generate a list of boolean buttons that
will be used to select what Level 0 text will be used to generate hierarchial
power plots.
Everything seems to run okay except that only the first boolean button in
the list shows up in the Form.
Anyone know what I am doing wrong here?
TIA,
David
.
.
.
/***** Create Fields for AppForm *****/
loopCntr = 1
xCrd = 20
yCrd = 90
foreach( labelItem labelList
printf( "%d %s\n", loopCntr labelItem )
if( loopCntr == 1
then
toggleList = list( hiCreateBooleanButton(
?name concat( strcat( "ppBool" labelItem ) )
?buttonText labelItem
?callback "boolCallBack()"
?defValue t
) xCrd:yCrd 100:80 80 )
else
myBoolList = list( hiCreateBooleanButton(
?name concat( strcat( "ppBool" labelItem ) )
?buttonText labelItem
?callback "boolCallBack()"
?defValue t
) xCrd:yCrd 100:80 80 )
toggleList = append( toggleList myBoolList )
) ;;; end if

loopCntr++
yCrd = yCrd+30
) ;;; end foreach

hiCreateAppForm(
?name 'BP_configForm
?formTitle "Batch Plot"
?callback list( "BPJnk1()" "BPJnk2()" )
?unmapAfterCB t
?buttonLayout 'OKCancelApply
?help ""
?fields list( toggleList )
) ;;; end hiCreateAppForm

hiDisplayForm( BP_configForm )
.
.
.
 
This modified one works.

toggleList was a flat list something like this toggleList =
list(list(formStr x:y x:y pw formStr x:y x:y pw formStr x:y x:y pw )).

Code is modified to make toggleList = list(list(formStr x:y x:y pw)
list(formStr x:y x:y pw) list(formStr x:y x:y pw) )

--
rgds,
Suresh J


/***** Create Fields for AppForm *****/
loopCntr = 1
xCrd = 20
yCrd = 90
labelList = list("a" "b" "c")
foreach( labelItem labelList
printf( "%d %s\n", loopCntr labelItem )
if( loopCntr == 1
then
toggleList = list( list(hiCreateBooleanButton(
?name concat( strcat( "ppBool"
labelItem ) )
?buttonText labelItem
?callback "boolCallBack()"
?defValue t
) xCrd:yCrd 100:80 80 ))
else
myBoolList = list( list(hiCreateBooleanButton(
?name concat( strcat( "ppBool"
labelItem ) )
?buttonText labelItem
?callback "boolCallBack()"
?defValue t
) xCrd:yCrd 100:80 80 ))
toggleList = append( toggleList
myBoolList )
) ;;; end if

loopCntr++
yCrd = yCrd+30
printf("toggleList = %L\n", toggleList)
) ;;; end foreach

BP_configForm = hiCreateAppForm(
?name 'BP_configForm
?formTitle "Batch Plot"
?callback list( "BPJnk1()" "BPJnk2()" )
?unmapAfterCB t
?buttonLayout 'OKCancelApply
?help ""
?fields toggleList
) ;;; end hiCreateAppForm

hiDisplayForm( BP_configForm )
David wrote:
The following snippet is used to generate a list of boolean buttons that
will be used to select what Level 0 text will be used to generate hierarchial
power plots.
Everything seems to run okay except that only the first boolean button in
the list shows up in the Form.
Anyone know what I am doing wrong here?
TIA,
David
.
.
.
/***** Create Fields for AppForm *****/
loopCntr = 1
xCrd = 20
yCrd = 90
foreach( labelItem labelList
printf( "%d %s\n", loopCntr labelItem )
if( loopCntr == 1
then
toggleList = list( hiCreateBooleanButton(
?name concat( strcat( "ppBool" labelItem ) )
?buttonText labelItem
?callback "boolCallBack()"
?defValue t
) xCrd:yCrd 100:80 80 )
else
myBoolList = list( hiCreateBooleanButton(
?name concat( strcat( "ppBool" labelItem ) )
?buttonText labelItem
?callback "boolCallBack()"
?defValue t
) xCrd:yCrd 100:80 80 )
toggleList = append( toggleList myBoolList )
) ;;; end if

loopCntr++
yCrd = yCrd+30
) ;;; end foreach

hiCreateAppForm(
?name 'BP_configForm
?formTitle "Batch Plot"
?callback list( "BPJnk1()" "BPJnk2()" )
?unmapAfterCB t
?buttonLayout 'OKCancelApply
?help ""
?fields list( toggleList )
) ;;; end hiCreateAppForm

hiDisplayForm( BP_configForm )
.
.
.
 
Thank you, Suresh!!
Works perfect :)

David

suresh j <sureshjeeva00@yahoo.com> wrote in message news:<3F8FCEE8.6060306@yahoo.com>...
This modified one works.

toggleList was a flat list something like this toggleList =
list(list(formStr x:y x:y pw formStr x:y x:y pw formStr x:y x:y pw )).

Code is modified to make toggleList = list(list(formStr x:y x:y pw)
list(formStr x:y x:y pw) list(formStr x:y x:y pw) )

--
rgds,
Suresh J


/***** Create Fields for AppForm *****/
loopCntr = 1
xCrd = 20
yCrd = 90
labelList = list("a" "b" "c")
foreach( labelItem labelList
printf( "%d %s\n", loopCntr labelItem )
if( loopCntr == 1
then
toggleList = list( list(hiCreateBooleanButton(
?name concat( strcat( "ppBool"
labelItem ) )
?buttonText labelItem
?callback "boolCallBack()"
?defValue t
) xCrd:yCrd 100:80 80 ))
else
myBoolList = list( list(hiCreateBooleanButton(
?name concat( strcat( "ppBool"
labelItem ) )
?buttonText labelItem
?callback "boolCallBack()"
?defValue t
) xCrd:yCrd 100:80 80 ))
toggleList = append( toggleList
myBoolList )
) ;;; end if

loopCntr++
yCrd = yCrd+30
printf("toggleList = %L\n", toggleList)
) ;;; end foreach

BP_configForm = hiCreateAppForm(
?name 'BP_configForm
?formTitle "Batch Plot"
?callback list( "BPJnk1()" "BPJnk2()" )
?unmapAfterCB t
?buttonLayout 'OKCancelApply
?help ""
?fields toggleList
) ;;; end hiCreateAppForm

hiDisplayForm( BP_configForm )
David wrote:
The following snippet is used to generate a list of boolean buttons that
will be used to select what Level 0 text will be used to generate hierarchial
power plots.
Everything seems to run okay except that only the first boolean button in
the list shows up in the Form.
Anyone know what I am doing wrong here?
TIA,
David
.
.
.
/***** Create Fields for AppForm *****/
loopCntr = 1
xCrd = 20
yCrd = 90
foreach( labelItem labelList
printf( "%d %s\n", loopCntr labelItem )
if( loopCntr == 1
then
toggleList = list( hiCreateBooleanButton(
?name concat( strcat( "ppBool" labelItem ) )
?buttonText labelItem
?callback "boolCallBack()"
?defValue t
) xCrd:yCrd 100:80 80 )
else
myBoolList = list( hiCreateBooleanButton(
?name concat( strcat( "ppBool" labelItem ) )
?buttonText labelItem
?callback "boolCallBack()"
?defValue t
) xCrd:yCrd 100:80 80 )
toggleList = append( toggleList myBoolList )
) ;;; end if

loopCntr++
yCrd = yCrd+30
) ;;; end foreach

hiCreateAppForm(
?name 'BP_configForm
?formTitle "Batch Plot"
?callback list( "BPJnk1()" "BPJnk2()" )
?unmapAfterCB t
?buttonLayout 'OKCancelApply
?help ""
?fields list( toggleList )
) ;;; end hiCreateAppForm

hiDisplayForm( BP_configForm )
.
.
.
 

Welcome to EDABoard.com

Sponsor

Back
Top