BookmarkSubscribeRSS Feed
jwillis
Quartz | Level 8

HI RW9,

SAS has the agility to do anything.  There are as many SAS coding styles as there are people coding SAS.  The DDE solution works today and is a solution that will also write to a specific cell in any excel spreadsheet. My coding style was developed to read from and write to specific sheets and cells in "Data Source Record" worksheets.  I have encountered all of the items listed in the SUGI proceedings paper link at least once and I am certain that once the DDE solution is no longer viable, the brilliant folks at SAS will be able to create a solution to replace the DDE method**.

SAS Community is a place where a community can come together to learn.  I monitor the community to learn new ideas, methods and solutions.  I believe the SAS DDE solution was built to solve the problem "...Excel has...a whole bunch of encoding around the variables and SAS doesn't know how to parse through it...."  I also believe that SAS will not let SAS users down.  I read your replies and I thank you for those replies.  I learn a great deal from all who reply.

**"Note that DDE may be used to create, delete, or rename spreadsheets, as well as to format worksheets and enter and delete formulas."


RW9
Diamond | Level 26 RW9
Diamond | Level 26

Whilst I am not disagreeing with you, MS has moved to the Open Office XML based format now, hence any application type of coding which can read and write text to a file should be able to do most things in Excel.  I can see one area where this is not the case, VBA macros are still held in a proprietary binary file within the XLSX.  However saying that, you could build the VBA, compile that, and then copy the file from the old XLSX into your created file before zipping up.  Note in this instance I had created all the structure, XML files and definitions manual and packaged them into a zip to create the XLSX rather than using tagsets.

PoojaM
Calcite | Level 5

Try Using something like this :

 

 

filename soy dde 'Excel|C:\Courses\Independent Study\Data\[SOYREF95.XLS]REF95!R2C2:R229C10';
data bean;
infile soy missover;
input labid $ month reps moisture abn dead abn1 abn2 abn3;
run;
proc print data=bean; run;

 

Link : http://www.ats.ucla.edu/stat/sas/library/SASRead_os.htm#ReadingExcelFilesIntoSAS

 

Thanks!

SAS Innovate 2025: Save the Date

 SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!

Save the date!

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
  • 17 replies
  • 42235 views
  • 4 likes
  • 6 in conversation