Choose Language Hide Translation Bar
Highlighted
G_M
G_M
Level III

Support needed: List not evaluating

Good afternoon,

 

Please advise

This is a two step case.  First step is to present user with check boxes in three clusters.
The check box items are Test1-4.  The user may select 1 or all check boxes and when they click
the Next Step Button, the "Something Important" Outline box should close and a string col box with
the selected tests should appear in an appended Outline box, "input values", which is in the step2 expr.
The list of selected items will not evaluate in the step2

Thanks in advance!

 

Names Default To Here( 1 );

/*This is a two step case.  First step is to present user with check boxes in three clusters.
The check box items are Test1-4.  The user may select 1 or all check boxes and when they click 
the Next Step Button, the "Something Important" Outline box should close and a string col box with
the selected tests should appear in an appended Outline box, "input values", which is in the step2 expr.
The list of selected items will not evaluate in the step2?*/


Test1 = "First";
Test2 = "Second";
Test3 = "Third";
Test4 = "Four"; 


step2 = Expr(
	ob1 = Outline Box( "Input Values", String Col Box( "Tests", Eval List( tests ) ), )
);


nw = New Window( "Example",
	vlb0 = V List Box(
		ob0 = Outline Box( "Something Important",
			H List Box(
				Panel Box( "Cluster1", cb0 = Check Box( Eval List( {Test1, Test2} ) ) ),
				Panel Box( "Cluster2", cb1 = Check Box( Eval List( {Test3} ) ), ),
				Panel Box( "Cluster4", cb2 = Check Box( Eval List( {Test4} ) ), ),

			), // end Hlb
			bbx = Border Box(
				H List Box(
					bb0 = Button Box( "Select All",
						cb0 << Set All( 1 );
						cb1 << Set All( 1 );
						cb2 << Set All( 1 );
					),
					bb1 = Button Box( "Next Step", 
					
					
						c1 = cb0 << Get Selected();
						c2 = cb1 << Get Selected();
						c3 = cb2 << Get Selected();
					
						tests = {};
				
						If( Sum( N Items( c1 ), N Items( c2 ), N Items( c3 ) ) == 0,
							ob0 << Close( 0 ),
							vlb0 << Append( Eval( step2 ) ) & ob0 << Close( 1 ) & 
								For( i = 1, i <= N Items( c1 ), i++,
								Insert Into( tests, c1[i] )
							) & For( j = 1, j <= N Items( c2 ), j++,
								Insert Into( tests, c2[j] )
							) & For( k = 1, k <= N Items( c3 ), k++,
								Insert Into( tests, c3[k] )
							)
						);, 
					
					),
					bb = Button Box( "Cancel", nw << Close Window ),

				), // end hlb
			),

		),

	), // end vlb0	
);

bbx << Left( 285 );
1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
G_M
G_M
Level III

Re: Support needed: List not evaluating

Thanks @ron_horne  for pointing out the issue with ordering actions from the Button Box.  The Append message needed to come at the end.

View solution in original post

1 REPLY 1
Highlighted
G_M
G_M
Level III

Re: Support needed: List not evaluating

Thanks @ron_horne  for pointing out the issue with ordering actions from the Button Box.  The Append message needed to come at the end.

View solution in original post

Article Labels