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

I frequently use the "View in Excel" right click context menu command to view files in the SAS Windows UI but would like to get rid of titles and column labels so that i can see the variable names instead of the labels.  I can eliminate the titles by submitting a title; prior to the view command but have not been able to eliminate the generation of labels.  Is there any way to modify the process to do this short of modifying the dataset?  Another oddity is that when labels are generated they are in multiple rows rather than in a single row.

1 ACCEPTED SOLUTION

Accepted Solutions
Reeza
Super User

I don't know if it's possible to change the GUI command but you can control all of that if you do it via code rather than the GUI.

 

Use either ODS EXCEL or PROC EXPORT - EXPORT Is likely closer to what you want.

 

proc export data=sashelp.class outfile='/home/fkhurshed/Class.xlsx' dbms=xlsx replace; run;

@eshupp wrote:

I frequently use the "View in Excel" right click context menu command to view files in the SAS Windows UI but would like to get rid of titles and column labels so that i can see the variable names instead of the labels.  I can eliminate the titles by submitting a title; prior to the view command but have not been able to eliminate the generation of labels.  Is there any way to modify the process to do this short of modifying the dataset?  Another oddity is that when labels are generated they are in multiple rows rather than in a single row.


 

View solution in original post

4 REPLIES 4
Reeza
Super User

I don't know if it's possible to change the GUI command but you can control all of that if you do it via code rather than the GUI.

 

Use either ODS EXCEL or PROC EXPORT - EXPORT Is likely closer to what you want.

 

proc export data=sashelp.class outfile='/home/fkhurshed/Class.xlsx' dbms=xlsx replace; run;

@eshupp wrote:

I frequently use the "View in Excel" right click context menu command to view files in the SAS Windows UI but would like to get rid of titles and column labels so that i can see the variable names instead of the labels.  I can eliminate the titles by submitting a title; prior to the view command but have not been able to eliminate the generation of labels.  Is there any way to modify the process to do this short of modifying the dataset?  Another oddity is that when labels are generated they are in multiple rows rather than in a single row.


 

eshupp
Obsidian | Level 7

Thanks for the alternative suggestion.  After some additional thought I determined that if I submit the following before doing a view the output is formatted the way I want:

TITLE;

OPTIONS NOLABEL;

 

This is an accep

eshupp
Obsidian | Level 7

I solved my problem by submitting OPTIONS NOTITLE; TITLE; before  performing "View in Excel".

Tom
Super User Tom
Super User

You can customize how Explorer works in Display Manager. 

image.png

Here is what the current entry that you are using looks like:

image.png

Looks like it is currently calling some SCL program that SAS supplied. 

AFA C=SASHELP.EXPLORER.EXCEL_TABLE_OPEN.SCL LIBRARY='%8b' TABLE='%32b';

You probably cannot change that program.  It is not clear if it has a option to NOT use the labels. 

 

But you could always either associate this menu item with a different command or make a new menu item that does what you want.

Ready to join fellow brilliant minds for the SAS Hackathon?

Build your skills. Make connections. Enjoy creative freedom. Maybe change the world. Registration is now open through August 30th. Visit the SAS Hackathon homepage.

Register today!
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
  • 4 replies
  • 678 views
  • 0 likes
  • 3 in conversation