<?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: JMP15 modal window with check box behavior in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/JMP15-modal-window-with-check-box-behavior/m-p/386956#M63711</link>
    <description>&lt;P&gt;I think your best solution, is to place the action to set variable itar, in a script that is executed when the check box is selected or unselected&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;ithead = "EAR Configuration for Factor Cross Plots";
itprompt = "Select to Include EAR warning on Factor Cross Plots.";
itwarn =
"WARNING – This document contains technical data classified under the Commerce Control List and assigned Export Control Classification Number (ECCN) 0A606.x and 0E606.";
//determine if itar/ear warning is required
itar = .;
itwin = New Window( ithead,
	&amp;lt;&amp;lt;Modal,
	H List Box( check1 = Check Box( itprompt,itar = check1 &amp;lt;&amp;lt; Get ), H List Box( "" ) ),
	

);
Show( itar );&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Wed, 19 May 2021 17:58:31 GMT</pubDate>
    <dc:creator>txnelson</dc:creator>
    <dc:date>2021-05-19T17:58:31Z</dc:date>
    <item>
      <title>JMP15 modal window with check box behavior</title>
      <link>https://community.jmp.com/t5/Discussions/JMP15-modal-window-with-check-box-behavior/m-p/386916#M63707</link>
      <description>&lt;P&gt;OK so I have code that worked fine in JMP 14, it went like this:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;ithead = "EAR Configuration for Factor Cross Plots";
itprompt = "Select to Include EAR warning on Factor Cross Plots.";
itwarn =
"WARNING – This document contains technical data classified under the Commerce Control List and assigned Export Control Classification Number (ECCN) 0A606.x and 0E606. ";

//determine if itar/ear warning is required
itwin = New Window( ithead,
	&amp;lt;&amp;lt;Modal,
	H List Box( check1 = Check Box( itprompt, ), H List Box( "" ) ), 

);
itar = check1 &amp;lt;&amp;lt; Get;
Show( itar );&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I see that now basically all the instances in my code where I try to get the output of a window after it closes don't work anymore in JMP15, and you can use On Close or on Validate to get most things working.&amp;nbsp; This has worked for me with text boxes and On Close.&amp;nbsp; In this case, I tried:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;ithead = "EAR Configuration for Factor Cross Plots";
itprompt = "Select to Include EAR warning on Factor Cross Plots.";
itwarn =
"WARNING – This document contains technical data classified under the Commerce Control List and assigned Export Control Classification Number (ECCN) 0A606.x and 0E606.";
//determine if itar/ear warning is required
itwin = New Window( ithead,
	&amp;lt;&amp;lt;Modal,
	H List Box( check1 = Check Box( itprompt, ), H List Box( "" ) ),
	&amp;lt;&amp;lt;On Validate( itar = check1 &amp;lt;&amp;lt; Get ),

);
Show( itar );&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN style="font-family: inherit;"&gt;If I use On Validate, I get the following error:&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;Object 'EvalContextBox' does not recognize the message 'On Validate'; perhaps you mean one of these: &amp;lt;&amp;lt;Inval Size &amp;lt;&amp;lt;Inval &amp;lt;&amp;lt;Journal &amp;lt;&amp;lt;Copy Data &amp;lt;&amp;lt;On Close &amp;lt;&amp;lt;Journal Window &amp;lt;&amp;lt;Horizontal Alignment &amp;lt;&amp;lt;Enabled.
&lt;/PRE&gt;
&lt;P&gt;&lt;SPAN style="font-family: inherit;"&gt;If I use On Close and don't choose the check box - there is no way to close the modal window.&amp;nbsp; Choosing OK does nothing and the X in the corner will also not close the modal window.&amp;nbsp; If I choose the check box, it returns 1 and works correctly.&amp;nbsp; If I choose the check box and then unchoose it, the window won't close.&amp;nbsp; How do I get a 0 value to return and be able to close the window?&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 09 Jun 2023 19:47:21 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/JMP15-modal-window-with-check-box-behavior/m-p/386916#M63707</guid>
      <dc:creator>jheadley</dc:creator>
      <dc:date>2023-06-09T19:47:21Z</dc:date>
    </item>
    <item>
      <title>Re: JMP15 modal window with check box behavior</title>
      <link>https://community.jmp.com/t5/Discussions/JMP15-modal-window-with-check-box-behavior/m-p/386949#M63710</link>
      <description>&lt;P&gt;Try the &lt;A href="https://www.jmp.com/support/help/en/16.0/#page/jmp/construct-a-modal-window.shtml" target="_self"&gt;&amp;lt;&amp;lt;Return Result message&lt;/A&gt; to get a list of the results of the dialog.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;itwin = New Window( ithead,
	&amp;lt;&amp;lt;Modal,
	&amp;lt;&amp;lt;Return Result,
	H List Box( check1 = Check Box( itprompt, ), H List Box( "" ) ), 

);
show(itwin);&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Log (when check box was checked):&lt;/P&gt;
&lt;PRE&gt;itwin = New Window( ithead,
	&amp;lt;&amp;lt;Modal,
	&amp;lt;&amp;lt;Return Result,
	H List Box( check1 = Check Box( itprompt, ), H List Box( "" ) ), 

);
show(itwin);

/*:

itwin = {check1 = {1}, Button(1)};&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 19 May 2021 17:48:32 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/JMP15-modal-window-with-check-box-behavior/m-p/386949#M63710</guid>
      <dc:creator>Jeff_Perkinson</dc:creator>
      <dc:date>2021-05-19T17:48:32Z</dc:date>
    </item>
    <item>
      <title>Re: JMP15 modal window with check box behavior</title>
      <link>https://community.jmp.com/t5/Discussions/JMP15-modal-window-with-check-box-behavior/m-p/386956#M63711</link>
      <description>&lt;P&gt;I think your best solution, is to place the action to set variable itar, in a script that is executed when the check box is selected or unselected&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;ithead = "EAR Configuration for Factor Cross Plots";
itprompt = "Select to Include EAR warning on Factor Cross Plots.";
itwarn =
"WARNING – This document contains technical data classified under the Commerce Control List and assigned Export Control Classification Number (ECCN) 0A606.x and 0E606.";
//determine if itar/ear warning is required
itar = .;
itwin = New Window( ithead,
	&amp;lt;&amp;lt;Modal,
	H List Box( check1 = Check Box( itprompt,itar = check1 &amp;lt;&amp;lt; Get ), H List Box( "" ) ),
	

);
Show( itar );&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 19 May 2021 17:58:31 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/JMP15-modal-window-with-check-box-behavior/m-p/386956#M63711</guid>
      <dc:creator>txnelson</dc:creator>
      <dc:date>2021-05-19T17:58:31Z</dc:date>
    </item>
    <item>
      <title>Re: JMP15 modal window with check box behavior</title>
      <link>https://community.jmp.com/t5/Discussions/JMP15-modal-window-with-check-box-behavior/m-p/387087#M63728</link>
      <description>this is the approach I ended up using - most direct. thanks!</description>
      <pubDate>Wed, 19 May 2021 23:59:18 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/JMP15-modal-window-with-check-box-behavior/m-p/387087#M63728</guid>
      <dc:creator>jheadley</dc:creator>
      <dc:date>2021-05-19T23:59:18Z</dc:date>
    </item>
    <item>
      <title>Re: JMP15 modal window with check box behavior</title>
      <link>https://community.jmp.com/t5/Discussions/JMP15-modal-window-with-check-box-behavior/m-p/387090#M63729</link>
      <description>I didn't know about the return result option - always good to learn new tricks, thanks.</description>
      <pubDate>Wed, 19 May 2021 23:59:44 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/JMP15-modal-window-with-check-box-behavior/m-p/387090#M63729</guid>
      <dc:creator>jheadley</dc:creator>
      <dc:date>2021-05-19T23:59:44Z</dc:date>
    </item>
  </channel>
</rss>

