Alteryx Server Discussions

Find answers, ask questions, and share expertise about Alteryx Server.

Send emails automatically even if attachments are open

kuntay
5 - Atom

Hi All,

 

I have a workflow which sends email attachments to the users from Alteryx Gallery. 

These attachments are available on shared drive and any 1 from my team can access these attachments.

 

Problem: When I am running this workflow it is getting failed because attachments are opened by someone. Is there a way where Alteryx should send emails even if the attachments are open by another user.

 

Thanks 

2 REPLIES 2
josephschafer
Alteryx Alumni (Retired)

Hi @kuntay 

 

Unfortunately this is a challenge when working with Excel files.  I believe what you'd need to do is make a copy of the excel file and then email the copy.  Obviously any unsaved changes wouldn't be copied over, but I think this should work for you. 

 

Here's a post that describes the general process you'd want to use:

 

https://community.alteryx.com/t5/Alteryx-Designer-Discussions/Automate-copy-and-paste-Excel-file-bef...

hroderick-thr
11 - Bolide

Alteryx really insists on exclusive access to files it reads and writes.

 

Use the Before Run event to run a bat file that copies your file to another file that no one will open. Then have your workflow use the copy. DOS copy doesn't care if it is open or not. The /y option overwrites it if it is already there. If you want to keep the filename intact for attachment, copy to a different directory and keep the same filename.

 

hroderick-thr_0-1597760944933.png