Excel application scope in shared folder

I am trying to create a excel file in shared folder with Excel application scope. file is getting created but is throwing exception:
• The file name or path does not exist.
• The file is being used by another program.
• The workbook you are trying to save has the same name as a currently open workbook

Could someone help me resolve this pls

@sravani22,

Make sure no one will open that Excel file. I think someone opened it because as you said it is in shared folder.

That is the new file which I am creating

It is likely due to the lag time between the robot’s computer and the file server. It is creating a file in the robot, then moving onto accessing it before the file server has it properly saved.

In the first activity, use a Retry activity, then put your application scope within it and save the output as a workbook variable. Leave the condition of the retry activity blank so it will simply retry on error. Only do one or two actions within this application scope as you don’t want actual errors to occur in here.

In the second activity, just use the application scope without the retry activity and resume your normal processing.

Hi Dave,
I didn’t get exactly what should I try.
I am just creating a new file. I do not have any other activity to do. Just creat a new file and exit. That’s it

Are you creating the new file inside a looping statement.

No sarathi. I am using excel application scope to create new empty excel file.

I am just using that activity independently

Hi,

I am trying like the following, compare the properties with this screenshot. It is not throwing any error for me.

Yup. I tried this. But this is not working when I try to save it in shared folder.

is there any other application working with the same excel which you are creating on the sharepath.

No sarathi.

Here is what I mean. It is checking that the file exists and re-tries creating the file 10 times with 1 second intervals until it is created.

Main.xaml (7.5 KB)

I have tested it in my environment by creating a new excel file in sharepath it is working fine. Ran multiple times, share your workflow please

It worked.
Excel application scope creats .xlsx file in default. No need to give extension manually.
But somehow it got worked other than shared folder (not manually adding .xlsx to file name). But its not working in shared folder ( we have to add extension .xlsx) to make it work.
Dont know the reason but its working .

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.