<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to avoid JMP Alert window in a JSL in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/How-to-avoid-JMP-Alert-window-in-a-JSL/m-p/462728#M70748</link>
    <description>&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );
If( N Table() == 0,
	dt = Current Data Table();
	Clear Symbols( dt );
	Try( dt = Open() );
	If( Is Empty( dt ), throw());
);&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Mon, 21 Feb 2022 17:11:05 GMT</pubDate>
    <dc:creator>txnelson</dc:creator>
    <dc:date>2022-02-21T17:11:05Z</dc:date>
    <item>
      <title>How to avoid JMP Alert window in a JSL</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-avoid-JMP-Alert-window-in-a-JSL/m-p/462707#M70745</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );

If( N Table() == 0, Open(), );

dt = Current Data Table();

//Create Lauch Window for prompting dialog
nw = New Window( &amp;lt;&amp;lt;Modal,
    V List Box(
        Lineup Box( N Col( 2 ), Spacing( 14 ), ),
        H List Box(
            Panel Box( "Select Columns", clb = Filter Col Selector( dt, all ) ),
            Panel Box( "Cast Selected Columns into Fit Model Roles",
                Lineup Box( N Col( 2 ),
                    Button Box( "Y, Response", clbY &amp;lt;&amp;lt; Append( clb &amp;lt;&amp;lt; Get Selected ) ),
                    clbY = Col List Box( "Numeric", MinItems( 1 ), nlines( 8 ) ), 

                    Button Box( "X, Two Samples",
                        clbXs &amp;lt;&amp;lt; Append( clb &amp;lt;&amp;lt; Get Selected )
                    ),
                    clbXs = Col List Box(
                        "Character",
                        MinItems( 1 ),
                        MaxItems( 1 ),
                        nlines( 1 )
                    ), 

                )
            ), 

            Panel Box( "Action",
                Button Box( "OK",
                    yVars = clby &amp;lt;&amp;lt; Get Items( "Column Reference" );
                    eVars = clbXs &amp;lt;&amp;lt; Get Items( "Column Reference" );
                ), 

                Button Box( "Cancel" ),
                Text Box(),
                Button Box( "Remove",
                    clbY &amp;lt;&amp;lt; Remove Selected;
                    clbXs &amp;lt;&amp;lt; Remove Selected;
                )
            ), 

        ),
        H List Box()
    )
);

If( nw["button"] == -1,
    Throw( "Cancelled!" )
);&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 09 Jun 2023 18:11:13 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-avoid-JMP-Alert-window-in-a-JSL/m-p/462707#M70745</guid>
      <dc:creator>Thomas1</dc:creator>
      <dc:date>2023-06-09T18:11:13Z</dc:date>
    </item>
    <item>
      <title>Re: How to avoid JMP Alert window in a JSL</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-avoid-JMP-Alert-window-in-a-JSL/m-p/462718#M70746</link>
      <description>&lt;P&gt;Open will throw an error if Cancel is pressed and you can catch it with Try-catch.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here(1);

Try(
	dt = Open();
,
	show(exception_msg);
);&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Do error handling in the catch part, example above will just print the message to log and lets script to continue running.&lt;/P&gt;</description>
      <pubDate>Mon, 21 Feb 2022 16:56:28 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-avoid-JMP-Alert-window-in-a-JSL/m-p/462718#M70746</guid>
      <dc:creator>jthi</dc:creator>
      <dc:date>2022-02-21T16:56:28Z</dc:date>
    </item>
    <item>
      <title>Re: How to avoid JMP Alert window in a JSL</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-avoid-JMP-Alert-window-in-a-JSL/m-p/462727#M70747</link>
      <description>&lt;P&gt;Thanks for your fast reply. What additional code must be added or changed after the open dialog is canceled (with no alert window) to stop the code from running the dialog window?&lt;/P&gt;</description>
      <pubDate>Mon, 21 Feb 2022 17:10:19 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-avoid-JMP-Alert-window-in-a-JSL/m-p/462727#M70747</guid>
      <dc:creator>Thomas1</dc:creator>
      <dc:date>2022-02-21T17:10:19Z</dc:date>
    </item>
    <item>
      <title>Re: How to avoid JMP Alert window in a JSL</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-avoid-JMP-Alert-window-in-a-JSL/m-p/462728#M70748</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here( 1 );
If( N Table() == 0,
	dt = Current Data Table();
	Clear Symbols( dt );
	Try( dt = Open() );
	If( Is Empty( dt ), throw());
);&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 21 Feb 2022 17:11:05 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-avoid-JMP-Alert-window-in-a-JSL/m-p/462728#M70748</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2022-02-21T17:11:05Z</dc:date>
    </item>
    <item>
      <title>Re: How to avoid JMP Alert window in a JSL</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-avoid-JMP-Alert-window-in-a-JSL/m-p/462733#M70752</link>
      <description>&lt;P&gt;Thanks, Jim. That was exactly what I was looking for.&lt;/P&gt;</description>
      <pubDate>Mon, 21 Feb 2022 18:44:46 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-avoid-JMP-Alert-window-in-a-JSL/m-p/462733#M70752</guid>
      <dc:creator>Thomas1</dc:creator>
      <dc:date>2022-02-21T18:44:46Z</dc:date>
    </item>
  </channel>
</rss>

