- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I am trying to send a report as the body of an email message. If I output the data as PDF, the report retains its gridlines. However, in the body fo the email the data appears without gridlines.
I tried adding style(report)=[rules=all frame = hsides] in the PROC REPORT statement to no result.
I would appreciate any suggestions. Thank you.
DeaT
libname xxx "/path";
FILENAME outbox email
to=("xxx@xxx.com")
type='text/html'
subject="xxx";
ods listing close;
ods html body=outbox ;
options nodate pageno=1 linesize=189 ;
PROC REPORT data=xxx.contacts(obs=5) split='*' nowd;
label customer_name = 'Cust*Name' customer_id = 'Cust*ID' fname='First*Name' lname='Last*Name'
work_phone_ext='Work*Phone*Ext' email='E-mail' contact_type='Contact*Type' ;
column Customer_name customer_id fname lname
work_phone_ext email contact_type ;
define action / display;
define customer_id / display;
define customer_name / display;
define fname / display;
define lname / display;
define work_phone_ext / display;
define email / display;
define contact_type / display;
Footnote;
Title J=C "xxxs";
Footnote1 'Total Updates =' "xxxt";
run;
ods html close;
ods listing;
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Hi, if the gridlines show when the output is viewed in the browser, then the issue is with the way the mail applications is causing the ODS HTML to be rendered. Once SAS is done with creating the HTML, it is up to the browser or other application to render the HTML into what you see on the screen.
In some browsers, the interior table lines are considered to be part of the background of the "web page" shown in the browser -- so sometimes when you printed the HTML page, the gridlines seemed to disappear. That sounds like what your mail program might be doing. You could "fiddle" with other styles, but the mail program might treat them the same way.
In the end, you may just need to educate the people who get the output that they should view the output in the browsers. Or stop sending them HTML output and send them a PDF file as an attachment and then they should be able to view in Acrobat, and/or print if they want.
cynthia
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
What is the ODS style you use for HTML output?
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
After I posted my original message, I noticed something else. If you right-click in Outlook and choose VIEW IN BROWSER, the gridlines are there. I even changed the borders to red to make sure I wasn't missing something: the border doesn't show up in the email message at all (even black), but it is displayed as expected in the browser view. I'm not sure what to make of it.
Thank you.
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Hi, if the gridlines show when the output is viewed in the browser, then the issue is with the way the mail applications is causing the ODS HTML to be rendered. Once SAS is done with creating the HTML, it is up to the browser or other application to render the HTML into what you see on the screen.
In some browsers, the interior table lines are considered to be part of the background of the "web page" shown in the browser -- so sometimes when you printed the HTML page, the gridlines seemed to disappear. That sounds like what your mail program might be doing. You could "fiddle" with other styles, but the mail program might treat them the same way.
In the end, you may just need to educate the people who get the output that they should view the output in the browsers. Or stop sending them HTML output and send them a PDF file as an attachment and then they should be able to view in Acrobat, and/or print if they want.
cynthia
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content