Page 1 of 1

Saving Workfile data to Excel (.xlsx) using wfsave

Posted: Tue Nov 14, 2017 5:00 am
by msj
My old code for saving Workfile Data to an .xls file worked like a charm:

write(t=xls,na=.,t,d=c,names,dates)".$folder1 . "\\export.xls fcst_1 fcst_2 fcst_3

Now, I would like to save the data to an .xlsx file using the new command wfsave. The current code I have now does not seem to work:

wfsave(type=excelxml)". $folder1 . "\\export.xlsx @keep fcst_1 fcst_2 fcst_3


Any suggestions or comments on how to fix the new code would be highly appreciated!

Re: Saving Workfile data to Excel (.xlsx) using wfsave

Posted: Tue Nov 14, 2017 9:28 am
by EViews Gareth
What is .$folder1 . ?

Re: Saving Workfile data to Excel (.xlsx) using wfsave

Posted: Wed Nov 15, 2017 12:33 am
by msj
Hello Gareth

Please excuse that I forgot to specify this. The code is written and executed in Perl and I specified that $folder1 = getcwd - get pathname of current working directory.

Re: Saving Workfile data to Excel (.xlsx) using wfsave

Posted: Wed Nov 15, 2017 9:04 am
by EViews Gareth
Well it looks ok to me, assuming you have the quotes and spaces in the right place.