<?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 Problem with ODS GRAPHICS to png format in Graphics Programming</title>
    <link>https://communities.sas.com/t5/Graphics-Programming/Problem-with-ODS-GRAPHICS-to-png-format/m-p/305193#M10736</link>
    <description>&lt;P&gt;I am trying to use ODS to output a sgrender plot. Able to&amp;nbsp;use ods rtf and outoput an rtf file. I need to outoput a png file as well.&lt;/P&gt;
&lt;P&gt;I am running into problems&amp;nbsp;with the png format.&lt;/P&gt;
&lt;P&gt;I am not able to get the titles into the png formatted graph. I am only getting the plot. I am using SAS EG (Version 6)&amp;nbsp;to execute my code.&lt;/P&gt;
&lt;P&gt;ods _all_ close;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;ods listing gpath = "xxx";&lt;/P&gt;
&lt;P&gt;ods graphics on /reset height= 3.25 in&lt;/P&gt;
&lt;P&gt;&amp;nbsp; width = 6.0 in reset imagefmt = png reset imagename = "TEST"&lt;/P&gt;
&lt;P&gt;border = off;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;proc sgrender data =xxx;&lt;/P&gt;
&lt;P&gt;title 1 "xxx";&lt;/P&gt;
&lt;P&gt;title 2 "yyy";&lt;/P&gt;
&lt;P&gt;run;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;ods graphics off;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;ods listing close;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;no errors in the log. png output is getting created but just the plot no titles. Any clues? appreciate your help.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 17 Oct 2016 19:37:33 GMT</pubDate>
    <dc:creator>bk1980</dc:creator>
    <dc:date>2016-10-17T19:37:33Z</dc:date>
    <item>
      <title>Problem with ODS GRAPHICS to png format</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Problem-with-ODS-GRAPHICS-to-png-format/m-p/305193#M10736</link>
      <description>&lt;P&gt;I am trying to use ODS to output a sgrender plot. Able to&amp;nbsp;use ods rtf and outoput an rtf file. I need to outoput a png file as well.&lt;/P&gt;
&lt;P&gt;I am running into problems&amp;nbsp;with the png format.&lt;/P&gt;
&lt;P&gt;I am not able to get the titles into the png formatted graph. I am only getting the plot. I am using SAS EG (Version 6)&amp;nbsp;to execute my code.&lt;/P&gt;
&lt;P&gt;ods _all_ close;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;ods listing gpath = "xxx";&lt;/P&gt;
&lt;P&gt;ods graphics on /reset height= 3.25 in&lt;/P&gt;
&lt;P&gt;&amp;nbsp; width = 6.0 in reset imagefmt = png reset imagename = "TEST"&lt;/P&gt;
&lt;P&gt;border = off;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;proc sgrender data =xxx;&lt;/P&gt;
&lt;P&gt;title 1 "xxx";&lt;/P&gt;
&lt;P&gt;title 2 "yyy";&lt;/P&gt;
&lt;P&gt;run;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;ods graphics off;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;ods listing close;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;no errors in the log. png output is getting created but just the plot no titles. Any clues? appreciate your help.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 17 Oct 2016 19:37:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Problem-with-ODS-GRAPHICS-to-png-format/m-p/305193#M10736</guid>
      <dc:creator>bk1980</dc:creator>
      <dc:date>2016-10-17T19:37:33Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with ODS GRPHICS to png format</title>
      <link>https://communities.sas.com/t5/Graphics-Programming/Problem-with-ODS-GRAPHICS-to-png-format/m-p/305195#M10737</link>
      <description>&lt;P&gt;Please post your log.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Ideally, also post code so we can run your code and replicate your issue. You can use datasets from SASHELP to start off with.&lt;/P&gt;
&lt;P&gt;Errors noted in your code so far:&lt;/P&gt;
&lt;P&gt;1. Spaces between title and number (Title 1 vs Title1)&lt;/P&gt;
&lt;P&gt;2. PROC SGRENDER doesn't seem to have data passed through, hard to say though.&lt;/P&gt;
&lt;P&gt;3. Spaces between in and measurement in height/weight statements.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Your SGTemplate also needs to account for the title somehow, so you may need changes there.&lt;/P&gt;
&lt;P&gt;This generates the graphic, but not in the correct directory so that may not be specified correctly.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;ods _all_ close;
 ods listing gpath = "C:\_LOCALdata\test.png";
ods graphics on /reset height= 3.25in
  width = 6in reset imagefmt = png reset imagename = "TEST"
border = off;
 
proc sgplot data =sashelp.class;
scatter x=height y=weight;
title1 "xxx";
title2 "yyy";
run;
 
ods graphics off;
 ods listing ;

&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 17 Oct 2016 19:35:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Graphics-Programming/Problem-with-ODS-GRAPHICS-to-png-format/m-p/305195#M10737</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-10-17T19:35:30Z</dc:date>
    </item>
  </channel>
</rss>

