Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.

Output error with Block Until Done tool

Stavi
7 - Meteor

Hey,

 

I try to write more then 4 sheets into the same excel file.

 

In order to avoid an error I chained multiple "block until done" tools, as show in the following screenshot:

 

Stavi_0-1652260203963.png

 

 

But I still get the following error:

Output Data: Unable to open file for write: (File Path...xlsx) The process cannot access the file because it is being used by another process. 

 

Stavi_2-1652260458041.png

 

 

Can you think why ?

 

                    Thanks in advance! 🙂🌷

6 REPLIES 6
IraWatt
17 - Castor
17 - Castor

Hey @Stavi,

To write to multiple sheets 4+ in the same excel file just use the output tool like this:

IraWatt_1-1652261586967.png

The tool takes the sheet name from your data. If you have any questions make sure to ask :) 

HTH,

Ira

 

 

Stavi
7 - Meteor

Thanks @IraWatt !

 

Do you meen use the union tool, and then defined "Take Table Name From Field"?

 

If so, in this case it is not relevant... The sheets have different columns so the union create "empty columns".

 

Please see the following example:

 

Stavi_0-1652263031097.png

 

 

Stavi_1-1652263054199.png

 

Stavi
7 - Meteor

@Adarc  🙂

IraWatt
17 - Castor
17 - Castor

Aahh okay I see the issue. In this case I would recommend a batch macro:

IraWatt_0-1652264970604.png

You pass it your sheet names then it removes empty columns for each one and updates the sheet name one at a time. 

IraWatt_1-1652265001090.png

In order to get this working you will need to tell it to update the sheet part of the address:

IraWatt_2-1652265089818.png

And also format your input tool correctly

IraWatt_3-1652265131883.png

 

 

 

 

 

IraWatt
17 - Castor
17 - Castor

If you have any questions setting it up make sure to ask:) there are also some great interactive videos on batch macros on the community, well worth checking out.

EdP
Alteryx
Alteryx

Additional suggestions can be found here:  https://knowledge.alteryx.com/index/s/article/Error-writing-Excel-file-to-Shared-Drive

Ed Phelps
Sr CSE
Alteryx
Labels