<?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 add a dynamically-created dashboard to the Scripts panel of a data table? in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/How-to-add-a-dynamically-created-dashboard-to-the-Scripts-panel/m-p/827887#M100967</link>
    <description>&lt;P&gt;&lt;a href="https://community.jmp.com/t5/user/viewprofilepage/user-id/5080"&gt;@DonMcCormack&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hi Don,&lt;/P&gt;&lt;P&gt;I use your solution now.&lt;/P&gt;&lt;P&gt;However, do you know why it is not possible to solve with Eval und Expr?&lt;BR /&gt;I believed that I just started to understand Eval and Eval Expr but it didn't work with"New Script"&lt;/P&gt;</description>
    <pubDate>Fri, 17 Jan 2025 13:00:17 GMT</pubDate>
    <dc:creator>Greenhorn</dc:creator>
    <dc:date>2025-01-17T13:00:17Z</dc:date>
    <item>
      <title>How to add a dynamically-created dashboard to the Scripts panel of a data table?</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-add-a-dynamically-created-dashboard-to-the-Scripts-panel/m-p/752690#M93427</link>
      <description>&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have a JSL script that lets the user choose one or more data files and then concatenates these files together into a data table. The script then creates a dashboard for the data table.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;To generate the JSL for the dashboard, I first manually created a dashboard (File -&amp;gt; New -&amp;gt; New Dashboard), adding manually-generated graphs to it in the Dashboard Builder; I then copied the dashboard code from the Dashboard Builder (red arrow -&amp;gt; Save Script -&amp;gt; To Script Window) and pasted it at the end of my JSL script.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This all works great -- however, my goal is to save the generated dashboard to the Scripts panel of the data table, in the same way that choosing red arrow -&amp;gt; Save Script -&amp;gt; To Data Table from the Dashboard Builder will save a dashboard to the data table. I'd also prefer to &lt;STRONG&gt;not&lt;/STRONG&gt; have the dashboard appear automatically (the user should click it in the Scripts panel when they want to see it).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I've tried searching the JSL reference PDF and the community discussions, but haven't found what I need. Can anyone point me in the right direction? Sanitized code is attached, omitting the data table generation.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Andy&lt;/P&gt;</description>
      <pubDate>Tue, 07 May 2024 16:13:07 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-add-a-dynamically-created-dashboard-to-the-Scripts-panel/m-p/752690#M93427</guid>
      <dc:creator>andyknc</dc:creator>
      <dc:date>2024-05-07T16:13:07Z</dc:date>
    </item>
    <item>
      <title>Re: How to add a dynamically-created dashboard to the Scripts panel of a data table?</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-add-a-dynamically-created-dashboard-to-the-Scripts-panel/m-p/752705#M93430</link>
      <description>&lt;P&gt;I don't use application builder and I would build the script in a different way. but maybe &lt;a href="https://community.jmp.com/t5/user/viewprofilepage/user-id/5080"&gt;@DonMcCormack&lt;/a&gt; has some ideas? This might have some ideas what you could do&amp;nbsp;&lt;A href="https://community.jmp.com/t5/Discovery-Summit-Americas-2023/Why-Aren-t-You-Using-App-Builder-Already-2023-US-30MP-1401/tac-p/705576" target="_blank" rel="noopener"&gt; Why Aren't You Using App Builder Already? - (2023-US-30MP-1401)&lt;/A&gt; (on same topic&lt;LI-MESSAGE title="Scripters Club 2024: Session 1 - Application Builder" uid="721547" url="https://community.jmp.com/t5/JMP-Scripters-Club-Discussions/Scripters-Club-2024-Session-1-Application-Builder/m-p/721547#U721547" discussion_style_icon_css="lia-mention-container-editor-message lia-img-icon-forum-thread lia-fa-icon lia-fa-forum lia-fa-thread lia-fa"&gt;&lt;/LI-MESSAGE&gt;)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 07 May 2024 16:28:15 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-add-a-dynamically-created-dashboard-to-the-Scripts-panel/m-p/752705#M93430</guid>
      <dc:creator>jthi</dc:creator>
      <dc:date>2024-05-07T16:28:15Z</dc:date>
    </item>
    <item>
      <title>Re: How to add a dynamically-created dashboard to the Scripts panel of a data table?</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-add-a-dynamically-created-dashboard-to-the-Scripts-panel/m-p/752759#M93436</link>
      <description>&lt;P&gt;You can try something like this:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;dashboardExpr = Expr(
	/* Code for JMP App goes here */
);

Eval(Substitute(
	Expr(Current Data Table() &amp;lt;&amp;lt; New Script("Dashboard",dbExpr)),
	Expr(dbExpr),Name Expr(dashboardExpr)
));&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Change &lt;FONT face="courier new,courier"&gt;Current Data Table()&lt;/FONT&gt; to the reference table to which you're adding the Dashboard. There might be other variables that need to be initialize before the Dashboard runs. The variable &lt;FONT face="courier new,courier"&gt;title&lt;/FONT&gt; on line 17 was causing problems as was the non-existant blob around line 24 (although I can understand why that wasn't included if you chose to leave it out).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 07 May 2024 20:06:07 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-add-a-dynamically-created-dashboard-to-the-Scripts-panel/m-p/752759#M93436</guid>
      <dc:creator>DonMcCormack</dc:creator>
      <dc:date>2024-05-07T20:06:07Z</dc:date>
    </item>
    <item>
      <title>Re: How to add a dynamically-created dashboard to the Scripts panel of a data table?</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-add-a-dynamically-created-dashboard-to-the-Scripts-panel/m-p/752806#M93443</link>
      <description>&lt;P&gt;Thanks Don! This works perfectly (and you are right about 'title' and the blob).&lt;/P&gt;</description>
      <pubDate>Wed, 08 May 2024 05:48:32 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-add-a-dynamically-created-dashboard-to-the-Scripts-panel/m-p/752806#M93443</guid>
      <dc:creator>andyknc</dc:creator>
      <dc:date>2024-05-08T05:48:32Z</dc:date>
    </item>
    <item>
      <title>Re: How to add a dynamically-created dashboard to the Scripts panel of a data table?</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-add-a-dynamically-created-dashboard-to-the-Scripts-panel/m-p/827887#M100967</link>
      <description>&lt;P&gt;&lt;a href="https://community.jmp.com/t5/user/viewprofilepage/user-id/5080"&gt;@DonMcCormack&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hi Don,&lt;/P&gt;&lt;P&gt;I use your solution now.&lt;/P&gt;&lt;P&gt;However, do you know why it is not possible to solve with Eval und Expr?&lt;BR /&gt;I believed that I just started to understand Eval and Eval Expr but it didn't work with"New Script"&lt;/P&gt;</description>
      <pubDate>Fri, 17 Jan 2025 13:00:17 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-add-a-dynamically-created-dashboard-to-the-Scripts-panel/m-p/827887#M100967</guid>
      <dc:creator>Greenhorn</dc:creator>
      <dc:date>2025-01-17T13:00:17Z</dc:date>
    </item>
    <item>
      <title>Re: How to add a dynamically-created dashboard to the Scripts panel of a data table?</title>
      <link>https://community.jmp.com/t5/Discussions/How-to-add-a-dynamically-created-dashboard-to-the-Scripts-panel/m-p/827888#M100968</link>
      <description>&lt;P&gt;How did you use it?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Edit:&lt;/P&gt;
&lt;P&gt;Hopefully this gives some ideas (I would assume it would work in similar way with dashboard expression)&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;Names Default To Here(1); 

dt = open("$SAMPLE_DATA/Big Class.jmp");
dt &amp;lt;&amp;lt; Delete Scripts(dt &amp;lt;&amp;lt; Get Table Script Names);


gb_expr = Expr(Graph Builder(
	Variables(X(:weight), Y(:height), Overlay(:sex)),
	Elements(Points(X, Y, Legend(9)), Line Of Fit(X, Y, Legend(11)))
));

Eval(Substitute(
	Expr(dt &amp;lt;&amp;lt; New Script("GB1", myexpr)),
	Expr(myexpr), Name Expr(gb_expr)
));

Eval(EvalExpr(
	dt &amp;lt;&amp;lt; New Script("GB2", Expr(Name Expr(gb_expr)));
));&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 17 Jan 2025 13:38:41 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/How-to-add-a-dynamically-created-dashboard-to-the-Scripts-panel/m-p/827888#M100968</guid>
      <dc:creator>jthi</dc:creator>
      <dc:date>2025-01-17T13:38:41Z</dc:date>
    </item>
  </channel>
</rss>

