<?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: JSL code to save picture is causing me to loose plot formatting color/marker/legend etc. please in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/JSL-code-to-save-picture-is-causing-me-to-loose-plot-formatting/m-p/59171#M32525</link>
    <description>&lt;P&gt;nevermind figure it out, Thanks again!!!&lt;/P&gt;</description>
    <pubDate>Mon, 04 Jun 2018 08:05:30 GMT</pubDate>
    <dc:creator>mattrholmes</dc:creator>
    <dc:date>2018-06-04T08:05:30Z</dc:date>
    <item>
      <title>JSL code to save picture is causing me to loose plot formatting color/marker/legend etc. please help</title>
      <link>https://community.jmp.com/t5/Discussions/JSL-code-to-save-picture-is-causing-me-to-loose-plot-formatting/m-p/59111#M32514</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am using the following code to try and save a picture of a varibility and time trend plots and it works but for some reason I loose the plots formatting,&amp;nbsp;color/marker/legend etc.&amp;nbsp; In this case&amp;nbsp;&lt;SPAN&gt;Flagging_Charts_Data_Var and Flagging_Charts_Data_Bivar are the handles for my variability and time trend plots.&lt;/SPAN&gt;This is probably something easy I am missing, please help, Thanks!!!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;//Code to try and save my plots as png&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Summary_Data_Flagging_Window = HListBox(Flagging_Charts_Data_Var,Flagging_Charts_Data_Bivar);&lt;BR /&gt;Summary_Data_Flagging_Window &amp;lt;&amp;lt; Save Picture(file_name,png);&lt;/P&gt;</description>
      <pubDate>Sat, 02 Jun 2018 22:12:14 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/JSL-code-to-save-picture-is-causing-me-to-loose-plot-formatting/m-p/59111#M32514</guid>
      <dc:creator>mattrholmes</dc:creator>
      <dc:date>2018-06-02T22:12:14Z</dc:date>
    </item>
    <item>
      <title>Re: JSL code to save picture is causing me to loose plot formatting color/marker/legend etc. please</title>
      <link>https://community.jmp.com/t5/Discussions/JSL-code-to-save-picture-is-causing-me-to-loose-plot-formatting/m-p/59113#M32516</link>
      <description>&lt;P&gt;My first thought is that the plots might not be finished drawing with your custom formatting&amp;nbsp;before the picture is saved.&amp;nbsp; I am not taken the time to understand exactly when it is necessary but I make a point to send '&amp;lt;&amp;lt; update window' before every image capture or save just to be safe.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is an overly complex example, but &lt;A href="https://community.jmp.com/t5/JMP-Add-Ins/3D-Plot-Tools/ta-p/48699" target="_self"&gt;this 3D Plot Tools add-in &lt;/A&gt;uses update window.&amp;nbsp; You can jump right to the source code on &lt;A href="https://github.com/himanga/JMP3DPlotTools/blob/master/src/main.jsl" target="_self"&gt;GitHub;&lt;/A&gt; search for "update window" to find the relevent lines (currently 145-148).&amp;nbsp;In this case, the update window message is sent to a 'Scatterplot 3D' window before&amp;nbsp;the graph inside that window is captured as an image.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-jsl"&gt;		//rotate the scatterplot
		sp[1] &amp;lt;&amp;lt; Frame3d( Set Rotation( x, y, z ) );
		
		//make sure the plot is redrawn
		sp[1] &amp;lt;&amp;lt; update window;
		
		//take a picture
		img = (sp[1] &amp;lt;&amp;lt; Find( Picture Box(1) )) &amp;lt;&amp;lt; Get Picture;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sun, 03 Jun 2018 01:56:54 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/JSL-code-to-save-picture-is-causing-me-to-loose-plot-formatting/m-p/59113#M32516</guid>
      <dc:creator>ih</dc:creator>
      <dc:date>2018-06-03T01:56:54Z</dc:date>
    </item>
    <item>
      <title>Re: JSL code to save picture is causing me to loose plot formatting color/marker/legend etc. please</title>
      <link>https://community.jmp.com/t5/Discussions/JSL-code-to-save-picture-is-causing-me-to-loose-plot-formatting/m-p/59114#M32517</link>
      <description>&lt;P&gt;Thanks for the reply, I don't think&amp;nbsp;that the speed&amp;nbsp;is the issue, I am think that there is something with the way you have to send the plot to the save picture() command but I am not familiar enough with JMP to know the answer, please if anyone else can help?&amp;nbsp; Thanks, Matt&lt;/P&gt;</description>
      <pubDate>Sun, 03 Jun 2018 04:14:43 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/JSL-code-to-save-picture-is-causing-me-to-loose-plot-formatting/m-p/59114#M32517</guid>
      <dc:creator>mattrholmes</dc:creator>
      <dc:date>2018-06-03T04:14:43Z</dc:date>
    </item>
    <item>
      <title>Re: JSL code to save picture is causing me to loose plot formatting color/marker/legend etc. please</title>
      <link>https://community.jmp.com/t5/Discussions/JSL-code-to-save-picture-is-causing-me-to-loose-plot-formatting/m-p/59128#M32522</link>
      <description>&lt;P&gt;Matt,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Try the attached script.&amp;nbsp; You will need to change the path, if you do not have a c:/temp/ drive.&amp;nbsp; Check to see if the color of the saved was removed.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Based upon experience, I have seen only these problems regarding colors:&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;The script is run, and before the save picture,&amp;nbsp; a data table clear rows states is called. In the script, you will see the statements varpic = report(varchart)[OutlineBox(2)] and bivpic = report(biv)[OutlineBox(1)]. Often people new to JSL think that this is capturing the graph as is, but in fact it is only creating a handle to the active (live) window. So any changes to the data table row states will be reflected on the graph when the save occurs.&lt;/LI&gt;&lt;LI&gt;Graph customizations are made to the frame box using variables. Those variables (not their values) are stored. If the&amp;nbsp;variables change or are deleted prior to saving the picture they will not show up in the picture.&lt;/LI&gt;&lt;LI&gt;There was one instance about 8 years ago, where JMP output as well as other statistical graphic output always came out black and white.&amp;nbsp; It was on a server where a default printer or graphics card had not been defined. I saw this only once.&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;So if the attached script saves the colors, and you are saving the pictures before closing or changing row states, then it might be the way you reference the graphs.&amp;nbsp; If the colors are stripped from the twopics.png, then it is a system thing.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You should note your OS and version of JMP.&amp;nbsp; Good Luck&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 04 Jun 2018 02:58:31 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/JSL-code-to-save-picture-is-causing-me-to-loose-plot-formatting/m-p/59128#M32522</guid>
      <dc:creator>gzmorgan0</dc:creator>
      <dc:date>2018-06-04T02:58:31Z</dc:date>
    </item>
    <item>
      <title>Re: JSL code to save picture is causing me to loose plot formatting color/marker/legend etc. please</title>
      <link>https://community.jmp.com/t5/Discussions/JSL-code-to-save-picture-is-causing-me-to-loose-plot-formatting/m-p/59165#M32524</link>
      <description>&lt;P&gt;Thanks for the excellent explanation and help, when I run the script you attached it works fine, however when I updated my code it created .png file's that were blank, maybe I am still missing something?&amp;nbsp; Should I not be using outlinebox[1]? I am using JMP Pro 11.1.1 on Win8.&amp;nbsp; I am also putting the entire code inside a loop to create multiple .png pictures, do I need to update the varpic or bivpic variables every time through the loop or the summarywindow?&amp;nbsp; Thanks so much again I think it is getting closer.&lt;/P&gt;</description>
      <pubDate>Mon, 04 Jun 2018 07:09:57 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/JSL-code-to-save-picture-is-causing-me-to-loose-plot-formatting/m-p/59165#M32524</guid>
      <dc:creator>mattrholmes</dc:creator>
      <dc:date>2018-06-04T07:09:57Z</dc:date>
    </item>
    <item>
      <title>Re: JSL code to save picture is causing me to loose plot formatting color/marker/legend etc. please</title>
      <link>https://community.jmp.com/t5/Discussions/JSL-code-to-save-picture-is-causing-me-to-loose-plot-formatting/m-p/59171#M32525</link>
      <description>&lt;P&gt;nevermind figure it out, Thanks again!!!&lt;/P&gt;</description>
      <pubDate>Mon, 04 Jun 2018 08:05:30 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/JSL-code-to-save-picture-is-causing-me-to-loose-plot-formatting/m-p/59171#M32525</guid>
      <dc:creator>mattrholmes</dc:creator>
      <dc:date>2018-06-04T08:05:30Z</dc:date>
    </item>
    <item>
      <title>Re: JSL code to save picture is causing me to loose plot formatting color/marker/legend etc. please</title>
      <link>https://community.jmp.com/t5/Discussions/JSL-code-to-save-picture-is-causing-me-to-loose-plot-formatting/m-p/59178#M32526</link>
      <description>&lt;P&gt;Congratulations!&lt;/P&gt;</description>
      <pubDate>Mon, 04 Jun 2018 10:00:25 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/JSL-code-to-save-picture-is-causing-me-to-loose-plot-formatting/m-p/59178#M32526</guid>
      <dc:creator>gzmorgan0</dc:creator>
      <dc:date>2018-06-04T10:00:25Z</dc:date>
    </item>
  </channel>
</rss>

