Hi,
I am getting the following error while writing in excel through dde session:
ERROR: DDE session not ready.
FATAL: Unrecoverable I/O error detected in the execution phase of the DATA step program.
Aborted during the EXECUTION phase.
code I am using:-
if fileexist(checklist_doc_path)
then do;
rc=system('"' !! checklist_doc_path !! '" 2>nul' );
submit continue;
filename cmds dde 'excel|[&docname]Checklist!r3c3:r7c3' notab;
data _null_;
** Try Opening the DDE System Channel to winword. *;
do until (fsysid > 0);
fsysid = FOPEN("cmds", 's');
x=sleep(1);
end;
rc = fclose(fsysid);
run;
filename cmds dde "excel|system";
data _null_;
file cmds;
Put '[workbook.activate("Checklist")]';
put '[select("r7c3:r7c3")]';
todaydate=put(Date(),date9.);
put "'" todaydate '0D'x;
put '[save]';
run;
endsubmit;
end;
Also, when i reassign my filename from
filename cmds dde "excel|system";
to
filename cmds dde 'excel|[&docname]Checklist!r3c3:r7c3' notab;
I get wrong entries(part of coding) populating my excel sheet. Please help!
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
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.