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

Hello Communities

 

I have created a Custom Report that includes a number of Proc Reports.

I need to export this to html, however I cannot change the font size of titles and tables (which the default is definitely too small).

 

Please note I CANNOT use ods html or Proc Export (the message I get is Insufficient authorization to access ......). I have been told my company won't change this setting....

 

I am using the Export Report as Step in Project; I can change the font size of the title, but this won't be reflected in the exported file; nor I can find how to change the size of the tables themselves.

 

In the properties, I can select different styles but they seem to use the same font size.

 

I'm using EG 7.13

 

could you please help?

 

Many thanks

 

1 ACCEPTED SOLUTION

Accepted Solutions
Cynthia_sas
SAS Super FREQ

Hi:

  You can easily change the font size of your titles by either 1) changing the style template (harder) or 2) changing the font size directly in the TITLE statement (easier). For example:

proc report data=sashelp.class(obs=3);
  title h=24pt color=purple 'My Purple Big Title';
  title2 h=10pt color=red 'My Red Small Title';
run;

  Results in this:

Cynthia_sas_0-1586962265784.png

 

As for changing the font size in the tables themselves, again you could 1) change the style template or 2) change the font directly in the procedure syntax:

title h=24pt color=purple 'My Purple Big Title';
title2 h=10pt color=red 'My Red Small Title';
proc report data=sashelp.class(obs=3)
  style(report)={font_size=18pt}
  style(header)={font_size=18pt}
  style(column)={font_size=10pt};
  column name age sex height weight;
  define name/ order 'Name' style(column)={font_size=14pt};
run;

which results in :

Cynthia_sas_1-1586962575408.png

  Note that the font size specified in the PROC REPORT statement applies to the entire report. Then the font size specified in the DEFINE statement (for NAME) overrides the first setting.

 

Hope this helps,

Cynthia

View solution in original post

9 REPLIES 9
Kurt_Bremser
Super User

Of course you can use ODS HTML or PROC EXPORT, you have to point the output to a location where you have write permission.

 

Copy/paste the log of your failed ODS or EXPORT code into a window opened with </>:

Bildschirmfoto 2020-04-07 um 08.32.59.png

MART1
Quartz | Level 8

Hello @Kurt_Bremser 

 

this is what the log shows (I've only replaced sensitive information with xxxx)

 

ERROR: Insufficient authorization to access 
       /sas1/sasconfig/Lev1/SASAppCorporate/\\serverf9.xxx.xxx.adgbs.com\users9\xxxxxx\Documents\.
NOTE: The SAS System stopped processing this step because of errors.
NOTE: There were 1 observations read from the data set SASHELP.CLASS.
NOTE: DATA statement used (Total process time):
      real time           0.00 seconds
      cpu time            0.00 seconds
      

0 records created in \\serverf9.xxx.xxxx.adgbs.com\users9\xxxxxx\Documents\ from SASHELP.CLASS

 

FYI below is the log when using  the step in project (which works)

 

File to Export
    SAS Report - Program
    Export even when errors occur in the file: Yes


Output File Type
    HTML Documents (*.html)

Options
    Use labels for column names: No


Output File
    \\serverf9.xxxx.xxxx.adgbs.com\users9\xxxxx\Documents\SAS Report - Program.html
    Overwrite Existing Output: Yes

Total Processing Time:
0.4350386 seconds

 

thanks

 

Kurt_Bremser
Super User

You are using a Windows-style UNC path on a UNIX system, and that won't work.

Since your path does not start with a slash (which means: at the root of the UNIX filesystem), the system assumes a relative path and starts at the current working directory (from where the SAS process was started); you are not allowed to write something there.

So you need to go looking for a place where you are allowed to write.

Check with the administrator of the SAS server if resource 

\\serverf9.xxx.xxx.adgbs.com\users9

is mounted somewhere on the UNIX server. If not, use a location in your home directory as intermediate storage and move the file from there later (by using WinSCP or similar):

ods html file="$HOME/SAS Report - Program.html";

$HOME is a UNIX environment variable that contains the absolute path of your home directory.

MART1
Quartz | Level 8

thanks @Kurt_Bremser 

 

I've resolved by using @Cynthia_sas solution for the moment - but will look into your suggestion

thanks

Cynthia_sas
SAS Super FREQ

Hi:

  You can easily change the font size of your titles by either 1) changing the style template (harder) or 2) changing the font size directly in the TITLE statement (easier). For example:

proc report data=sashelp.class(obs=3);
  title h=24pt color=purple 'My Purple Big Title';
  title2 h=10pt color=red 'My Red Small Title';
run;

  Results in this:

Cynthia_sas_0-1586962265784.png

 

As for changing the font size in the tables themselves, again you could 1) change the style template or 2) change the font directly in the procedure syntax:

title h=24pt color=purple 'My Purple Big Title';
title2 h=10pt color=red 'My Red Small Title';
proc report data=sashelp.class(obs=3)
  style(report)={font_size=18pt}
  style(header)={font_size=18pt}
  style(column)={font_size=10pt};
  column name age sex height weight;
  define name/ order 'Name' style(column)={font_size=14pt};
run;

which results in :

Cynthia_sas_1-1586962575408.png

  Note that the font size specified in the PROC REPORT statement applies to the entire report. Then the font size specified in the DEFINE statement (for NAME) overrides the first setting.

 

Hope this helps,

Cynthia

MART1
Quartz | Level 8

Hi @Cynthia_sas 

 

that's great thanks.

 

just one more thing: the title changes the font size in the Results (in SAS) but when exported it to html, it does not.

Do you know how to change it when exported?

 

again many thanks

 

Cynthia_sas
SAS Super FREQ

Hi:

  When I use an ODS HTML "sandwich" around my code, everything looks OK in the browser (I used FireFox). I don't know what you mean when you say "exported to HTML". How are you doing an "export" other than using ODS HTML.

 

  Please see this example:

Cynthia_sas_0-1587068338334.png

 

Hope this helps,

Cynthia

MART1
Quartz | Level 8
I use the "Step in Project", but you are right it works the way you suggested (not sure what I did at the beginning)
thanks
MART1
Quartz | Level 8
great many thanks @Cynthia_sas

that works perfectly!

SAS Innovate 2025: Save the Date

 SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!

Save the date!

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.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 9 replies
  • 3224 views
  • 1 like
  • 3 in conversation