Choose Language Hide Translation Bar

How do I make combo box to show unique values?

Hello, 

 

I am working on a dynamic dialog box. Bellow is a part of my scripts. I expect the dialog box show me a text box when "Just Paste" is selected for users to past. I will be appreciate a lot if someone can help.

 

Thanks,

 

My script is bellow:

 

 

Clear Globals();
new window("Module Selection Criteria",
Panel Box( "Pull by......",
rb1 = Radio Box( {"Sub ID", "Box ID"} ),
rb2 = Radio Box({"By Date Table", "Just Paste"},
If(
(rb2<<Get Selected) == "Just Paste",
V List Box(
Text Box( " " ),
Text Box( "Paste Straight from JMP or Excel" ),
Text Box( "SubIDs ONLY" ),
Text Box( "" ),
Script Box( "", 280, 140 )
)
)
),
)
)

 

 

0 Kudos
1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
txnelson
Super User

Re: How do I make combo box to show unique values?

Here are a couple of ways to handle the issue

Clear Globals();
New Window( "Module Selection Criteria",
	Panel Box( "Pull by......",
		rb1 = Radio Box( {"Sub ID", "Box ID"} ),
		rb2 = Radio Box(
			{"By Date Table", "Just Paste"},
			If( (rb2 << Get Selected) == "Just Paste",
				myVLB << Visibility( "Visible" );
				Wait( 5 );
				myVLB << Visibility( "collapse" );
			)
		),
		MyVLB = V List Box(
			Text Box( " " ),
			Text Box( "Paste Straight from JMP or Excel" ),
			Text Box( "SubIDs ONLY" ),
			Text Box( "" ),
			Script Box( "", 280, 140 )
		)
	)
);
MyVLB << visibility( "collapse" );
Clear Globals();
New Window( "Module Selection Criteria",
	myPanel = Panel Box( "Pull by......",
		rb1 = Radio Box( {"Sub ID", "Box ID"} ),
		rb2 = Radio Box(
			{"By Date Table", "Just Paste"},
			If( (rb2 << Get Selected) == "Just Paste",
				myPanel << append(
					V List Box(
						Text Box( " " ),
						Text Box( "Paste Straight from JMP or Excel" ),
						Text Box( "SubIDs ONLY" ),
						Text Box( "" ),
						Script Box( "", 280, 140 )
					)
				)
			)
		)
	)
);

 

Jim

View solution in original post

0 Kudos
2 REPLIES 2
Highlighted
txnelson
Super User

Re: How do I make combo box to show unique values?

Here are a couple of ways to handle the issue

Clear Globals();
New Window( "Module Selection Criteria",
	Panel Box( "Pull by......",
		rb1 = Radio Box( {"Sub ID", "Box ID"} ),
		rb2 = Radio Box(
			{"By Date Table", "Just Paste"},
			If( (rb2 << Get Selected) == "Just Paste",
				myVLB << Visibility( "Visible" );
				Wait( 5 );
				myVLB << Visibility( "collapse" );
			)
		),
		MyVLB = V List Box(
			Text Box( " " ),
			Text Box( "Paste Straight from JMP or Excel" ),
			Text Box( "SubIDs ONLY" ),
			Text Box( "" ),
			Script Box( "", 280, 140 )
		)
	)
);
MyVLB << visibility( "collapse" );
Clear Globals();
New Window( "Module Selection Criteria",
	myPanel = Panel Box( "Pull by......",
		rb1 = Radio Box( {"Sub ID", "Box ID"} ),
		rb2 = Radio Box(
			{"By Date Table", "Just Paste"},
			If( (rb2 << Get Selected) == "Just Paste",
				myPanel << append(
					V List Box(
						Text Box( " " ),
						Text Box( "Paste Straight from JMP or Excel" ),
						Text Box( "SubIDs ONLY" ),
						Text Box( "" ),
						Script Box( "", 280, 140 )
					)
				)
			)
		)
	)
);

 

Jim

View solution in original post

0 Kudos
Highlighted

Re: How do I make combo box to show unique values?

Thank you so much for your rapid reply Jim! Your answer is very helpful!

0 Kudos