<?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 set the title for a html page created through a stored process? in Developers</title>
    <link>https://communities.sas.com/t5/Developers/how-to-set-the-title-for-a-html-page-created-through-a-stored/m-p/3625#M1777</link>
    <description>I know what you mean. But, sadly, I think that it's not possible. The client applications are SO flexible -- in letting the end-user select how the results should be returned -- HTML, RTF, SASReport XML, CSV, etc -- and (TITLE=) is just not appropriate for all destinations. It would require a boatload more conditional logic in %stpbegin to ignore the (TITLE=) for destinations where it was not appropriate.&lt;BR /&gt;
 &lt;BR /&gt;
cynthia</description>
    <pubDate>Thu, 28 Jun 2007 12:28:33 GMT</pubDate>
    <dc:creator>Cynthia_sas</dc:creator>
    <dc:date>2007-06-28T12:28:33Z</dc:date>
    <item>
      <title>how to set the title for a html page created through a stored process?</title>
      <link>https://communities.sas.com/t5/Developers/how-to-set-the-title-for-a-html-page-created-through-a-stored/m-p/3620#M1772</link>
      <description>Hi,&lt;BR /&gt;
&lt;BR /&gt;
does anyone know how I can specify the title to be displayed in the browsers title bar, when using the %stpbegin and %stpend macros in a stored process?&lt;BR /&gt;
&lt;BR /&gt;
In plain SAS I would use e.g.&lt;BR /&gt;
&lt;BR /&gt;
ods html body='c:\temp\class.html'(title='Students');&lt;BR /&gt;
proc print data=sashelp.class;&lt;BR /&gt;
run;&lt;BR /&gt;
ods html close;&lt;BR /&gt;
&lt;BR /&gt;
to set 'Students' as the browser title. For the stp generated pages I always get 'SAS Output'.&lt;BR /&gt;
&lt;BR /&gt;
Thanks,&lt;BR /&gt;
Frank</description>
      <pubDate>Tue, 26 Jun 2007 14:11:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/how-to-set-the-title-for-a-html-page-created-through-a-stored/m-p/3620#M1772</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2007-06-26T14:11:23Z</dc:date>
    </item>
    <item>
      <title>Re: how to set the title for a html page created through a stored process?</title>
      <link>https://communities.sas.com/t5/Developers/how-to-set-the-title-for-a-html-page-created-through-a-stored/m-p/3621#M1773</link>
      <description>Remember that not all client applications are receiving the stored process results in a browser. So the title= suboption will NOT work in all the client applications.&lt;BR /&gt;
 &lt;BR /&gt;
I do not actually know whether title= works in the Stored Process Web Application or the Information Delivery Portal. I would NOT expect TITLE= to work in Web Report Studio or the SAS Add-in for Microsoft Office. It MAY work in EG, depending on how you write your stored process.&lt;BR /&gt;
 &lt;BR /&gt;
So, for example, when I wrote this as a stored process:&lt;BR /&gt;
[pre]&lt;BR /&gt;
%let odsoptions=(title="My Report");&lt;BR /&gt;
 &lt;BR /&gt;
%stpbegin;&lt;BR /&gt;
proc print data=sashelp.class;&lt;BR /&gt;
  title 'The SAS Title';&lt;BR /&gt;
run;&lt;BR /&gt;
%stpend;&lt;BR /&gt;
[/pre]&lt;BR /&gt;
 &lt;BR /&gt;
As long as the client application returned HTML results (such as in EG), the title was used (I had to open the output in a separate IE window to see the title). But, when I executed this stored process using the SAS Add-in for Microsoft Office (Word), the stored process failed because TITLE= is not a valid option when used within the context of the Add-in.&lt;BR /&gt;
 &lt;BR /&gt;
cynthia</description>
      <pubDate>Tue, 26 Jun 2007 14:49:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/how-to-set-the-title-for-a-html-page-created-through-a-stored/m-p/3621#M1773</guid>
      <dc:creator>Cynthia_sas</dc:creator>
      <dc:date>2007-06-26T14:49:47Z</dc:date>
    </item>
    <item>
      <title>Re: how to set the title for a html page created through a stored process?</title>
      <link>https://communities.sas.com/t5/Developers/how-to-set-the-title-for-a-html-page-created-through-a-stored/m-p/3622#M1774</link>
      <description>sorry, I forgot to mention that I'm using the SASStoredProcess web application.&lt;BR /&gt;
Anyway, your suggestion doesn't work for me.&lt;BR /&gt;
According to the documentation at &lt;A href="http://support.sas.com/rnd/itech/doc9/dev_guide/stprocess/reserved.html" target="_blank"&gt;http://support.sas.com/rnd/itech/doc9/dev_guide/stprocess/reserved.html&lt;/A&gt; I changed your example to&lt;BR /&gt;
&lt;BR /&gt;
%let _odsoptions=(title="My Report");&lt;BR /&gt;
%stpbegin;&lt;BR /&gt;
proc print data=sashelp.class;&lt;BR /&gt;
  title 'The SAS Title';&lt;BR /&gt;
run;&lt;BR /&gt;
%put _all_;&lt;BR /&gt;
%stpend;&lt;BR /&gt;
&lt;BR /&gt;
but it failes with&lt;BR /&gt;
&lt;BR /&gt;
3         +%let _odsoptions=(title="My Report");&lt;BR /&gt;
4         +%stpbegin;&lt;BR /&gt;
ERROR 22-322: Syntax error, expecting one of the following: ;, ANCHOR, ARCHIVE, ATTRIBUTES, BASE, BODY, CHARSET, CLOSE, CODE, CONTENTS, CSS, ENCODING, FILE, FRAME, GFOOTNOTE, GPATH, GTITLE, &lt;BR /&gt;
              HEADTEXT, METATEXT, NEWFILE, NOGFOOTNOTE, NOGTITLE, PAGE, PARAMETERS, PATH, RECORD_SEPARATOR, STYLE, STYLESHEET, TEXT, TRANTAB.  &lt;BR /&gt;
ERROR 202-322: The option or parameter is not recognized and will be ignored.&lt;BR /&gt;
4           (title="My Report")&lt;BR /&gt;
            _&lt;BR /&gt;
            22&lt;BR /&gt;
             _____&lt;BR /&gt;
             202&lt;BR /&gt;
5         +proc print data=sashelp.class;&lt;BR /&gt;
6         +  title 'The SAS Title';&lt;BR /&gt;
7         +run;&lt;BR /&gt;
&lt;BR /&gt;
I guess this happens, because title is not an independent option but a sub-option of the body option - is this correct?&lt;BR /&gt;
&lt;BR /&gt;
Thanks,&lt;BR /&gt;
Frank</description>
      <pubDate>Tue, 26 Jun 2007 15:14:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/how-to-set-the-title-for-a-html-page-created-through-a-stored/m-p/3622#M1774</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2007-06-26T15:14:38Z</dc:date>
    </item>
    <item>
      <title>Re: how to set the title for a html page created through a stored process?</title>
      <link>https://communities.sas.com/t5/Developers/how-to-set-the-title-for-a-html-page-created-through-a-stored/m-p/3623#M1775</link>
      <description>OK...well as long as you're using the Stored Process Web Application, then try this:&lt;BR /&gt;
[pre]&lt;BR /&gt;
ods html file=_webout(title="My Report2");&lt;BR /&gt;
  proc print data=sashelp.class;&lt;BR /&gt;
     title 'The SAS Title';&lt;BR /&gt;
  run;&lt;BR /&gt;
ods html close;&lt;BR /&gt;
[/pre]&lt;BR /&gt;
 &lt;BR /&gt;
But remember that using this form of writing the stored process may limit you to where (what client applications) your stored process can be executed from.&lt;BR /&gt;
 &lt;BR /&gt;
cynthia</description>
      <pubDate>Tue, 26 Jun 2007 15:36:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/how-to-set-the-title-for-a-html-page-created-through-a-stored/m-p/3623#M1775</guid>
      <dc:creator>Cynthia_sas</dc:creator>
      <dc:date>2007-06-26T15:36:44Z</dc:date>
    </item>
    <item>
      <title>Re: how to set the title for a html page created through a stored process?</title>
      <link>https://communities.sas.com/t5/Developers/how-to-set-the-title-for-a-html-page-created-through-a-stored/m-p/3624#M1776</link>
      <description>thanks, Cynthia, but due to the implications you mention, I'm not going to follow this route.&lt;BR /&gt;
I just wished there was something as simple as a _ODSTITLE macro variable, which would be honored by the %stpbegin macro.&lt;BR /&gt;
&lt;BR /&gt;
-Frank</description>
      <pubDate>Thu, 28 Jun 2007 08:41:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/how-to-set-the-title-for-a-html-page-created-through-a-stored/m-p/3624#M1776</guid>
      <dc:creator>deleted_user</dc:creator>
      <dc:date>2007-06-28T08:41:35Z</dc:date>
    </item>
    <item>
      <title>Re: how to set the title for a html page created through a stored process?</title>
      <link>https://communities.sas.com/t5/Developers/how-to-set-the-title-for-a-html-page-created-through-a-stored/m-p/3625#M1777</link>
      <description>I know what you mean. But, sadly, I think that it's not possible. The client applications are SO flexible -- in letting the end-user select how the results should be returned -- HTML, RTF, SASReport XML, CSV, etc -- and (TITLE=) is just not appropriate for all destinations. It would require a boatload more conditional logic in %stpbegin to ignore the (TITLE=) for destinations where it was not appropriate.&lt;BR /&gt;
 &lt;BR /&gt;
cynthia</description>
      <pubDate>Thu, 28 Jun 2007 12:28:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/how-to-set-the-title-for-a-html-page-created-through-a-stored/m-p/3625#M1777</guid>
      <dc:creator>Cynthia_sas</dc:creator>
      <dc:date>2007-06-28T12:28:33Z</dc:date>
    </item>
    <item>
      <title>Re: how to set the title for a html page created through a stored process?</title>
      <link>https://communities.sas.com/t5/Developers/how-to-set-the-title-for-a-html-page-created-through-a-stored/m-p/3626#M1778</link>
      <description>&lt;B&gt;Usage Note 38254: How to use the ODS TITLE option with the %STPBEGIN macro&lt;/B&gt;&lt;BR /&gt;
&lt;A href="http://support.sas.com/kb/38/254.html" target="_blank"&gt;http://support.sas.com/kb/38/254.html&lt;/A&gt;&lt;BR /&gt;
&lt;BR /&gt;
As Cynthia said, this will fail for some destinations.&lt;BR /&gt;
&lt;BR /&gt;
Vince DelGobbo&lt;BR /&gt;
SAS R&amp;amp;D</description>
      <pubDate>Thu, 13 May 2010 23:58:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Developers/how-to-set-the-title-for-a-html-page-created-through-a-stored/m-p/3626#M1778</guid>
      <dc:creator>Vince_SAS</dc:creator>
      <dc:date>2010-05-13T23:58:34Z</dc:date>
    </item>
  </channel>
</rss>

