BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
steilber
Calcite | Level 5

I have a macro that uses DDE to write an Excel workbook with several worksheets.  The name of the workbook is a concatenation of the path name, a string constant, and a macro variable that contains the product name.  I need to update the macro to add an invocation for a new product that has a slash in the name, as in %let product = 'Product This/That'.  For that run, the workbook is not created, and the message in the log is

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.

I have tried %quote with the variable assignment, and the SYMBOLGEN parameter indicates that the variable is resolving correctly. I've also tried increasing the sleep time. The workbook appears to be correctly populated in my Excel display. The macro works fine for all other invocations in the SAS program, before and after this one. Does anyone have an idea about why it works for all the macro variable values except that one?

1 ACCEPTED SOLUTION

Accepted Solutions
art297
Opal | Level 21

If you are on some version of windows, I don't believe that character is valid in a filename as it is the indicator for a subdirectory.

View solution in original post

4 REPLIES 4
twocanbazza
Quartz | Level 8

Remove SAS from the picture and try and manually create a workbook and/or sheet, called  'Product This/That' - does it work?

steilber
Calcite | Level 5

No, it doesn't.  Thanks for the idea!  I thought only a backslash would be a problem, but that showed me the forward slash doesn't work either.

art297
Opal | Level 21

If you are on some version of windows, I don't believe that character is valid in a filename as it is the indicator for a subdirectory.

steilber
Calcite | Level 5

You are right!  I thought it would only balk at the backslash.  Thanks to you and to twocanbazza!  I've been trying to get past this problem for a long time.

hackathon24-white-horiz.png

The 2025 SAS Hackathon has begun!

It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.

Latest Updates

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
  • 3852 views
  • 3 likes
  • 3 in conversation