BookmarkSubscribeRSS Feed
CHUNantes
Obsidian | Level 7

Hello.

 

Our users are using Add-in Office Excel to run a Store Process and generate a dashboard in Excel.

 

When running the STP, user is prompted to choose between storing the result in a new worksheet or use the current one and specify the cell to use.

 

No matter which option you choose, Excel open a new worksheet to display the result and the file is always named Main.xlsx

 

Here is the start of our STP where we specify the name wanted :

 

%global _odsdest _odsstyle _odsstylesheet;

%let _odsdest=excel;
%let _odsstyle=sasweb;
%let _odsstylesheet=;

data _null_;
rc = stpsrv_header('Content-type','application/vnd.ms-excel;');
rc = stpsrv_header('Content-disposition','attachment; filename=BilanDesLits.xlsx');
run;

*ProcessBody;
%stpbegin;

 

What's wrong ? Is there another option to set the filename ?

 

Regards.