DATA Step, Macro, Functions and more

pasting output in Word

Reply
Occasional Contributor
Posts: 16

pasting output in Word

I am trying to get my results output to Word. This has worked before but now I get the following error message. Can someone suggest how to solve this? Thanks.

 

ods rtf file = "/folders/myfolders/2017/RAPP/RAPPAHANNOCK 2017 CREEL RESULTS.rtf"
99 ! BODYTITLE;
WARNING: BODYTITLE and BODYTITLE_AUX cannot be changed in mid document.
Contributor
Posts: 30

Re: pasting output in Word

Posted in reply to vicdicenzo

FYI...

Specify that the titles and footnotes are to be placed into the body of the RTF document and not into the header and footer sections BODYTITLE
Specify that the titles and footnotes are to be placed into the body of the RTF document and not into the header and footer sections. The titles and footnotes will also be placed into cells or tables. BODYTITLE_AUX
Super User
Posts: 13,347

Re: pasting output in Word

Posted in reply to vicdicenzo

If you have already started writing to the same ODS RTF file as it says, you cannot change the behavior of bodytitle or bodytitle_aux.

Either move that to the first reference of the ODS RTF or use another approach.

 

Is suspect "worked before" meant that you set the option on the first reference to a specific destination file and then closed the document.

 

If you need to place text into the body and have previously not set the bodytitle you might try adding ODS TEXT RTF statements or Proc ODS TEXT to simulate titles. You would want to make sure that you have used title; footnote; prior to that so that the current titles don't appear if not wanted.

Occasional Contributor
Posts: 16

Re: pasting output in Word

I do not understand either of these responses. What additional info can I provide to clear this up?

Super User
Posts: 13,347

Re: pasting output in Word

Posted in reply to vicdicenzo

vicdicenzo wrote:

I do not understand either of these responses. What additional info can I provide to clear this up?


Post the log from the entire program.

Paste it into a code box opened with the forum's {I} menu icon.

Occasional Contributor
Posts: 16

Re: pasting output in Word

OPTIONS LS=100 PS=100 NOCENTER NODATE NONUMBER;

/** Import an XLSX file. **/

PROC IMPORT DATAFILE="/folders/myfolders/2017/RAPP/COVER.XLSX"
OUT=WORK.COVER
DBMS=XLSX
REPLACE;
RUN;

/** Import an XLSX file. **/

PROC IMPORT DATAFILE="/folders/myfolders/2017/RAPP/EFFORT.XLSX"
OUT=WORK.EFFORT
DBMS=XLSX
REPLACE;
RUN;

/** Import an XLSX file. **/

PROC IMPORT DATAFILE="/folders/myfolders/2017/RAPP/CATCH.XLSX"
OUT=WORK.CAT
DBMS=XLSX
REPLACE;
RUN;

PROC IMPORT DATAFILE="/folders/myfolders/2017/RAPP/OPINION.XLSX"
OUT=WORK.SOCIAL
DBMS=XLSX
REPLACE;
RUN;


ods rtf file = "/folders/myfolders/2017/RAPP/RAPPAHANNOCK RIVER CREEL RESULTS 2017.rtf" BODYTITLE;
Ask a Question
Discussion stats
  • 5 replies
  • 167 views
  • 0 likes
  • 3 in conversation