cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
bjsebeck
Frequent Visitor

Excel Run Script File syntax issues.

I've got a flow that I'm building where a portion of it involves using the Sharepoint "Get File Content" and "Create File" commands to create a duplicate of an Excel workbook in a specified location.  I intend to then run a script on this workbook duplicate.

 

I'm having issues with getting a "The parameter 'file' has an invalid value" error that I've tried multiple routes to clear without any luck. 

 

I've tried after a failure, before I delete that file that was created, using the folder navigator to select that file manually, then deleting the file (so that the Create File doesn't fail), and that errors out saying "Workbook not found", but when I navigate to the folder, there it is.  I've also tried adding a delay of up to 5 minutes between the Create File and the Run Script with no impact.

 

I've tried initializing a variable and hard coding the initial value to be the exact same thing that the file navigator returns when I do that route.  Theoretically, the syntax should be correct then.  But that gives me the invalid value error.

 

I feel like I've just got a syntax error of some kind, but when I feed it the syntax that it's looking for, it tells me that the workbook isn't there when it definitely is.

 

Any help would be appreciated.

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
GeoffRen
Microsoft
Microsoft

The name of the file is not what is being used. It is the file id. You can use the Peek Code feature found in the menu of any of the Excel actions to see what the id looks like for your files.

 

So when you delete and recreate a file, that file will have a different id even if it has the same name. Instead of hard coding in the file name, you need to use Dynamic content to get the id of the file you want to work with.

 

View solution in original post

1 REPLY 1
GeoffRen
Microsoft
Microsoft

The name of the file is not what is being used. It is the file id. You can use the Peek Code feature found in the menu of any of the Excel actions to see what the id looks like for your files.

 

So when you delete and recreate a file, that file will have a different id even if it has the same name. Instead of hard coding in the file name, you need to use Dynamic content to get the id of the file you want to work with.

 

View solution in original post

Helpful resources

Announcements
Process Advisor

Introducing Process Advisor

Check out the new Process Advisor community forum board!

MPA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

Users online (64,026)