概述
此示例说明如何使用与用户在先前的 ListBox 中所做的选择相关的选项动态填充 ComboBox。
指示
在 JMP® 会话中,单击文件菜单并选择新建 ► 脚本。复制以下脚本并将其粘贴到脚本窗口中。要运行示例脚本,请单击编辑菜单并选择运行脚本。
/* Open a sample data table */
dt = Open( "$SAMPLE_DATA\Big Class.jmp", "Invisible" );
/* Extract a list of unique ages */
Summarize( a = By( :age ) );
/* Create a modal dialog */
New Window( "Example",
<<MODAL>", 1 );
cb2 << Set Items( ageNames );
)
)
)
), /* Print the selected values from the ListBox and ComboBox in the log */
Panel Box( "Select a Name:",
cb2 = Combo Box(
{"<SELECT name="">"},
<
Additional Documentation
More information about the JMP Scripting Language can be found in the JMP Scripting Guide. You can access the guide from within JMP by clicking on the Help menu and select JMP Help. From the online Table of Contents, choose Scripting Guide.
[Previously JMP Note 54614]</SELECT></MODAL>