I am trying to create and use a style with the following ODS in an scl web app. When I use the following code I get the error message that style cannot be found. The log shows the style is being saved. Can you please explain where I am going wrong?
Just a few comments to add to what David said. Are you using either SAS/IntrNet and an SCL program or a SAS Stored Process (calling an SCL program)?
If so, you may find that your updated style template needs to be written to an item store or template store that "lives" on a server that is accessible to your platform configuration (SAS/IntrNet Application Server or Stored Process Server). (In other words, you cannot write the updated template to your personal C: drive.)
Next, if you are trying to open your result file with Excel (as indicated by your appsrv_header function), you may find that ODS HTML does not work as well as ODS HTML3. It turns out that ODS HTML in SAS 9 creates HTML 4.01 compliant tags and Excel is much happier with HTML 3.2 compliant tags. You may want to invoke ODS HTML3 instead of ODS HTML in your invocation code.
Finally to reiterate what David said, you need to control your new template location with a libname and an ODS PATH statement. Something like this:
libname mytemp 'server-path-location-for-changed-templates';
With this code, a folder or directory named "styles" will be created in the item store "mytemp.templat". Inside the "styles" folder, you will be creating a new style template called "dashboard". However, you will only want to write to mytemp.templat when you are creating or updating your new template. (Probably 1 time) Most of the time, when running jobs, you will just need to POINT to the new item store on the server like this:
You guys rock! Your advice worked like a charm. I utilized the save library and therefore did not need the libname statement. Yes, I am using SAS/IntrNet and an SCL program. Your suggestion regarding HTML3 also improved performance.