Date: Tue, 9 Sep 2003 09:43:49 -0500
Reply-To: "Smith, Curtis, Mr, DCAA" <Curtis.Smith@DCAA.MIL>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: "Smith, Curtis, Mr, DCAA" <Curtis.Smith@DCAA.MIL>
Subject: Re: DDE to Excel freezes SAS
Content-Type: text/plain; charset="us-ascii"
The form of the filename statement that I always use looks like the
following:
filename xlout DDE "excel|c:\temp\[new.xls]sheet1!r2c1:r65536c27" notab;
The difference being that before the worksheet filename, I have the file
path defined (notice it does not appear within the brackets). Maybe in
your case SAS is not finding a path to write the xls file.
-----Original Message-----
From: m n [mailto:iced_phoenix@YAHOO.COM]
Sent: Tuesday, September 09, 2003 7:00 AM
To: SAS-L@LISTSERV.UGA.EDU
Subject: Re: DDE to Excel freezes SAS
Prasad,
Thanks for your reply. I was aware that my code did not write anything
out...The point was that the code I provided is the simplest code that
freezes SAS. When I add code to actually write to Excel (similar to
yours below), the situation is no different--SAS still freezes just as
before. Any ideas?
Matt
prasad.s.ravi@HOUSEHOLD.COM (Prasad S Ravi) wrote in message
news:<OFDC5EB6FC.0FFAB059-ON86256D9B.007AA0A1@household.com>...
> Matt:
>
>
> There should be more to your code, you are not writing out anything
> to the excel file.
> Add the following at the bottom of your code and try it again.
>
>
> filename cmds dde 'excel|system';
> FILENAME exlout DDE "EXCEL|[book1]SHEET1!R1C1:R10C1";
>
>
> data _null_;
> file exlout;
> set your_data;
> put your_variables;
> run;
>
>
>
> Prasad Ravi
>
>
>
>
>
>
> m n
> <iced_phoenix@YAHOO.C To:
SAS-L@LISTSERV.UGA.EDU
> OM> cc:
> Sent by: "SAS(r) Subject: DDE to Excel
freezes SAS
> Discussion"
> <SAS-L@LISTSERV.UGA.E
> DU>
>
>
> 09/08/2003 02:44 PM
> Please respond to m n
>
>
>
>
>
>
> Dear SAS-L,
>
> I want to start using DDE to automate the exportation of SAS datasets
> to Excel. However, my attempts at doing ANYTHING with DDE results in
> SAS simply freezing. For instance, a job like the following opens
> Excel, but SAS freezes and I have to end its process (note: line
> numbers are inserted by me for easier reference):
>
> 01 options noxwait noxsync;
> 02 x "C:\Office2k\Office\Excel.exe";
> 03
> 04 data _null_;
> 05 x=sleep(5);
> 06 run;
> 07
> 08 filename test dde 'excel|system';
> 09
> 10 data _null_;
> 11 file test;
> 12 run;
>
> This is the simplest job that exhibits the problem. If I comment out
> lines 10 through 12(the file statement), the program runs with no
> error and SAS does not freeze. So it seems that SAS is freezing on
> the file statement. I'm running SAS Release 8.00 TS Level 00M0 on
> Windows NT Version 5.0.2195.
>
> Any ideas?
>
> Matt
|