BookmarkSubscribeRSS Feed
ruchiy
Calcite | Level 5

I am trying to call excel macro from sas 9.3 EG connection from my local server.

But I am getting the following error in the initial step itself of opening a excel. I am new to SAS DDE, please help me


17         %sysexec md "&path.Report";

18         options noxwait noxsync obs=max;

                   _______

                   13

ERROR 13-12: Unrecognized SAS option name NOXWAIT.

18       ! options noxwait noxsync obs=max;

                           _______

                           13

ERROR 13-12: Unrecognized SAS option name NOXSYNC.

19         X "'C:\Program Files (x86)\Microsoft Office\Office14\EXCEL.exe'"

19       !                                                                 ;

4 REPLIES 4
ruchiy
Calcite | Level 5

I am not getting anything

its simply saying

18        

19         X "dir"

19       !        ;

20        

21        

22        

23         %LET _CLIENTTASKLABEL=;

24         %LET _CLIENTPROJECTPATH=;

25         %LET _CLIENTPROJECTNAME=;

26         %LET _SASPROGRAMFILE=;

27        

28         ;*';*";*/;quit;run;

29         ODS _ALL_ CLOSE;

30        

31        

32         QUIT; RUN;

Kurt_Bremser
Super User

Issuing

X "dir";

in my local SAS session (not EG) resulted in an open cmd window with the contents of the directory listing and a prompt (issued without noxwait).

Open your Server list, right mouse click on the active server, tab "Software", "View Initialization Log". This may give you a clue where the server actually resides.

RichardinOz
Quartz | Level 8

Microsoft DDE only works when both the application issuing the DDE statements and the target application are on the same Windows platform.  Typically, when using SAS EG, the core SAS application resides on a server (which may or may not be a Windows server) but the Excel instance is on a local machine.  SAS EG, even though it is located locally, is not itself involved in DDE; it merely issues SAS code to the server to be executed.  Use EG file import/export to move data between Excel and SAS.

Despite its many merits, (and many champions), DDE is legacy technology which, as you have found, is not scalable in a client server (EG) situation.  Microsoft and others did toy with the idea of making it more generic but it didn't happen and we now have to find repoacement methods.

I have some sympathy for you if you have been given some code to run.  You can only make DDE work if you have Base SAS (and Excel) installed on your desktop, or you can adapt the code to work on a Windows server where you have SAS.   If your workplace can provide that, good.  Otherwise you have been set a task you cannot complete.

Richard.

SAS Innovate 2025: Register Now

Registration is now open for SAS Innovate 2025 , our biggest and most exciting global event of the year! Join us in Orlando, FL, May 6-9.
Sign up by Dec. 31 to get the 2024 rate of just $495.
Register now!

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
  • 4 replies
  • 4543 views
  • 0 likes
  • 3 in conversation