BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
GreggB
Pyrite | Level 9

When I submit the following code, I get this error: 

ERROR: A component of C:\Users\gbibb\AppData\Local\Temp\SAS Temporary

       Files\_TD3472_DO-GBIBB-LT2_\G:\Departments\Research\MAP\1415\Longitudinal Match\Spring to

       Spring\math_long_match_by_Spr14_ELEMschool.xls is not a directory.

ERROR: No body file. HTML output will not be created.

HOWEVER, when I submit the same code a 2nd time, it works fine.  Is SAS creating a directory on the first submit that allows it to work on the second submit?

Code:

proc sort data=map2;

by school;

run;

ODS html body='G:\Departments\Research\MAP\1415\Longitudinal Match\Spring to Spring\math_long_match_by_Spr14_ELEMschool.xls';

proc tabulate data=MAP2;

by school;

where grade_s14 ne '' and grade_s13 ne '' and grade_s12 ne '' and grade_s14 not in ('10','11','12','9','8','7','6');

class grade_s14 grade_s13 grade_s12 Math_Met_SS_1314 Math_Met_SS_1213;

table grade_s12*grade_s13*grade_s14, Math_Met_SS_1213*(n*f=6.0 pctn<Math_Met_SS_1213>='PCT'*f=6.1) Math_Met_SS_1314*(n*f=6.0 pctn<Math_Met_SS_1314>='PCT'*f=6.1) / rts=25 box=_page_condense;

title'math results';

run;

ods html close;

1 ACCEPTED SOLUTION

Accepted Solutions
ballardw
Super User

I've seen this happen and is a combination of preferences using the work folder for default output. The referenced

C:\Users\gbibb\AppData\Local\Temp\SAS Temporary

       Files\_TD3472_DO-GBIBB-LT2_\

part of the error was very likely the location of the WORK library.

If I recall correctly HTML output works better with a Path="G:\Departments\Research\MAP\1415\Longitudinal Match\Spring to Spring" Body="math_long_match_by_Spr14_ELEMschool.xls" reference.

And since you apparently actually want Excel output you might use ODS tagsets.Excelxp and create Excel readable xml files.


View solution in original post

3 REPLIES 3
ballardw
Super User

I've seen this happen and is a combination of preferences using the work folder for default output. The referenced

C:\Users\gbibb\AppData\Local\Temp\SAS Temporary

       Files\_TD3472_DO-GBIBB-LT2_\

part of the error was very likely the location of the WORK library.

If I recall correctly HTML output works better with a Path="G:\Departments\Research\MAP\1415\Longitudinal Match\Spring to Spring" Body="math_long_match_by_Spr14_ELEMschool.xls" reference.

And since you apparently actually want Excel output you might use ODS tagsets.Excelxp and create Excel readable xml files.


GreggB
Pyrite | Level 9

Thanks.  You actually touched on the real problem -- I need to learn more about using tagsets.  I've done some reading on them but haven't gotten a handle on it.  Any readings you can suggest would be greatly appreciated.

Gregg

ballardw
Super User

I suspect if you search this forum for "tagsets.excelxp" you will find more than enough examples (right and wrong) to get started.

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 3 replies
  • 2792 views
  • 1 like
  • 2 in conversation