Hi,
I'm trying to create a UI to input a JMP file using button box and generating graph in the same window in Vlistbox.
Here's me code: It gives me an error because the data table isn't selected. Any suggestions?
Names Default To Here( 1 );
New Window( "",
modal,
Button Box( " Click to Open", dt = Open( "$SAMPLE_DATA/Big Class.jmp" ) ),
V List Box(
obj = dt << Graph Builder(
Variables( X( :Sex ), Y( :Height ), Group X( :Age ) ),
Elements( Box Plot( X, Y ) )
)
)
);
You need to defer filling in the VLB until the button is pressed. Also, you can use the Platform() function to help with table scoping (speaking of scoping, you can use the window pseudo-namespace to help with scoping)
New Window( "Test",
Modal
,
Button Box( " Click to Open",
window:dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
window:vlb << Append(
Platform( window:dt,
window:obj = window:dt << Graph Builder(
Variables( X( :Sex ), Y( :Height ), Group X( :Age ) ),
Elements( Box Plot( X, Y ) )
)
)
)
)
,
window:vlb = V List Box()
);
You need to defer filling in the VLB until the button is pressed. Also, you can use the Platform() function to help with table scoping (speaking of scoping, you can use the window pseudo-namespace to help with scoping)
New Window( "Test",
Modal
,
Button Box( " Click to Open",
window:dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
window:vlb << Append(
Platform( window:dt,
window:obj = window:dt << Graph Builder(
Variables( X( :Sex ), Y( :Height ), Group X( :Age ) ),
Elements( Box Plot( X, Y ) )
)
)
)
)
,
window:vlb = V List Box()
);