Help using Base SAS procedures

Problem of replace an exist excel file

Reply
Regular Contributor
Posts: 222

Problem of replace an exist excel file


Hello everyone,

I have a problem of creating a new excel file from SAS and replace an exist  excel file,

for example ,I have c:\temp\one.xls with a sheet named sheetone.

I want to update this excel file use SAS code:

PROC EXPORT DATA=sashelp.class

OUTFILE = "C:\Temp\one.xls"

DBMS = EXCEL2002 REPLACE;

SHEET = "sheetone";

RUN;

BUT this will not replace sheetone, it will create another sheet named sheetone1.

Please help!

Thanks

Mike

SAS Super FREQ
Posts: 8,868

Re: Problem of replace an exist excel file

Posted in reply to Mike_Davis

Hi:

You might want to work with Tech Support. I don't remember a DBMS= option named EXCEL2002. It looks in the doc, like the valid values are:

EXCEL, EXCEL4, EXCEL5, EXCELCS and XLS and that EXCEL covers all versions from 97 thru 2003.

from: http://support.sas.com/documentation/cdl/en/acpcref/63181/HTML/default/viewer.htm#p1d0tocg3njhmfn1d4...

  So if you are having issues with your PROC EXPORT, you might work with Tech Support to figure out whether there are other issues at work (such as the 32-bit or 64-bit status of both SAS and Microsoft Office; the operating system (Windoes 7 or Windows XP) or the version of SAS you are using 9.2 versus 9.3 versus using SAS EG).

cynthia

PROC Star
Posts: 7,485

Re: Problem of replace an exist excel file

Posted in reply to Cynthia_sas

Mike: In answer to how to open a ticket with tech support:  http://support.sas.com/ctx/supportform//createForm

Weren't there a number of other posts in this thread?  If you delete a message you end up also deleting all of the responses to that message.

Ask a Question
Discussion stats
  • 2 replies
  • 204 views
  • 6 likes
  • 3 in conversation