We are celebrating the 10-year anniversary of the Alteryx Community! Learn more and join in on the fun here.
Start Free Trial

Alteryx Designer Desktop Discussions

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

"Unable to open file for write" error when writing to multiple worksheets in excel

SaleemB
6 - Meteoroid

I am using "Take File/Table Name From Field" in my output tool to write to an excel workbook where different items will write to different worksheets.  It almost always errors out at some point in the process as it tries to write to the different worksheets.  It seems to be because the OS takes a certain amount of time to close the file and if alteryx attempts to open and write to it during this time it throws an error.  My example file below errors out randomly on any of the 100 individual worksheet writes on my system.  There doesn't seem to be a way to address this or add a conditional expression in the output tool to have it wait until the file is closed before attempting to open it again.  The specific error is:

 

 

 

	Output Data (4)	Unable to open file for write: \\vncrp1001\ud04$\x183490\My Documents\test1.xlsx - Can't open file: \\vncrp1001\ud04$\x183490\My Documents\test1.xlsx: The process cannot access the file because it is being used by another process. (32)

 

 

2 REPLIES 2
Luke_C
17 - Castor
17 - Castor

Hi @SaleemB 

 

I haven't been able to reproduce with your workflow. It may be worth noting what version you're on and whether or not you're using AMP.

SaleemB
6 - Meteoroid

Thanks for replying!  I'm on Version 2022.1.1.25127 and I tried it both using AMP and with AMP unselected.  Same error.  I also find it weird that although the records are numbered sequentially, the output goes out of order.  Seems like it should output the records sequentially as well.

 

 
 

 

 

Labels
Top Solution Authors