cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Billy1988
Helper I
Helper I

Error: File not found

Hi,

My workflow looks like this:

A user enters the name of the document in PowerApps and clicks "OK". Now the workflow in Power Automate starts.

The workflow copies a MASTER file in a specified folder and does a rename (what the user has specified as the name).

This all works, but now comes my problem. 80% of the time the user has to write a % character in the name.
These are chemistry documents and the names of the products usually contain a % sign. But then the workflow aborts with the message:

"File Not Found
clientRequestId: 916cf910-57f9-468f-87b9-69af5670b6c7
serviceRequestId: 916cf910-57f9-468f-87b9-69af5670b6c7"

This means:
"test" works
"test%" does not work

How can I solve this problem?


Thanks in advance!!!!

1 ACCEPTED SOLUTION

Accepted Solutions

@jkb @Expiscornovus 
i have found a workaround that works for me. But notice i am using powerapps to start the workflow.
I have a text field called "test"
i set the onSelect from the button to: 
Set(varMaterialName; Substitute(DataCard_test.Text; "%"; "percent"));;

I also set the default property from the text field to  varMaterialName
if a user now enters a % sign, it is first converted to "percent" and then the workflow starts

I hope this workaround helps someone

View solution in original post

7 REPLIES 7
Expiscornovus
Super User
Super User

Hi @Billy1988,


Can you share a couple of screenshots of your flow setup? Specifically the copy and rename actions would be interesting to troubleshoot.

Billy1988
Helper I
Helper I

@Expiscornovus 

yes, of course... it is in german... i hope you can deal with it.

Billy1988_0-1619093375576.pngBilly1988_1-1619093473370.png

 

The second image is the important part...  If the file is created then i do some other things in Sharepoint
but this is not important for the problem...

The workflow aborts when trying to create the document with % in the name.

Thank you for the help!

Expiscornovus
Super User
Super User

Hi @Billy1988,

 

Just to double check. You are using the create file action, correct? Is there a reason why you aren't using the copy file instead of the create file action?

 

I will try and see if I can reproduce this behaviour with the create file action.

 

In the meantime as a workaround you could try and use the copy file action and use a send http request to sharepoint action to rename the file afterwards via the fileleafref property.

 

Below is an example of that approach.

 

1. Add a copy file action. 

copywithnewname.png

 

2. Add a Send an HTTP request to SharePoint action. Use the following configuration. Use the ID of the copy file action. And use the dateierstellen input for the fileleafref.

 

URI

 

_api/web/lists/getbytitle('Destination')/items(@{outputs('Copy_file')?['body/ItemId']})

 

 

Headers

 

{
  "Content-Type": "application/json;odata=nometadata",
  "X-HTTP-Method": "MERGE",
  "If-Match": "*"
}

 

 

Body

 

{ 'FileLeafRef': '@{variables('Dateierstellen')}'}

 

 

renamefile_sharepoint.png

 

jkb
Regular Visitor

I have encountered a similar issue using the SharePoint "Get file content using path" action.

 

File path with URL encoded filename 20210421_090027%5B1%5Dtest.jpg fails with error "Action 'Get_file_content_using_path' failed" and error details "File not found."

 

The URL is valid and accessible, however the flow fails presumably because of the %5B and %5D escaped characters for [ and ].

 

Actual file name: 20210421_090027[1]test.jpg

Encoded file name that fails: 20210421_090027%5B1%5Dtest.jpg

@Expiscornovus  Thank you for the effort and your reply.

The reason is because I didn't know how to customize the name with the copy file. That is why I did not take that. With the create file I could pass a filename from PowerApps. If there is no other way, then I will use your workaround, but maybe you can please look again with the create file, because that is not so complicated 🙂

somewhere powerautomate has a problem with the %   😕


@jkb @Expiscornovus 
i have found a workaround that works for me. But notice i am using powerapps to start the workflow.
I have a text field called "test"
i set the onSelect from the button to: 
Set(varMaterialName; Substitute(DataCard_test.Text; "%"; "percent"));;

I also set the default property from the text field to  varMaterialName
if a user now enters a % sign, it is first converted to "percent" and then the workflow starts

I hope this workaround helps someone

View solution in original post

Consider to include active variables from the dinamic content, in the sample attached the correct one is "Identifier".ObtenerContenidoArchivoX.jpg

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Top Solution Authors
Top Kudoed Authors
Users online (2,807)