Hey everyone!
I do not really have a lot of experience with automate, so apologies if this is an easy question.
Currently I have documents that have titles with a consistent format. An example is "Agreement - US714 - 38256025 - 06-2020", where US714 is the item ID, 38256025 the user ID and 06-2020 the month and year. When copying these files into our SharePoint, I would like to use this document title to populate some metadata fields inside the document library. I would, for example, like the metadata field "User ID" to automatically have the "38256025" value, the metadata field "item ID" to have US714", etc, by using the data provided in the document title.
I got a bit stuck when trying to do this, however , and I was wondering if this is at all possible? I was personally thinking I would have to use the "update metadata" field, but I didn't get it to work.
Any help would be greatly appreciated!
Hi @Anonymous ,
You could refer to screenshot below to create the flow:
Expression for the Date as below:
last(split(outputs('Compose'),' - '))
Expression for the item id as below:
first(skip(split(outputs('Compose'),' - '),1))
Expression for the user id as below:
first(skip(split(outputs('Compose'),' - '),2))
Best Regards,
Alice
Community Support Team _ Alice Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
I do not see much details about your flow.
You can achieve your requirement with string function "split". You can find the documentation below:
https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/functions/function-split
In your Title, I see you have " - " between each value. You can split the whole string with " - ". Then, you will get an array with each element. You can use the array's individual elements to set your desired fields.
I hope this will help you.
Regards
Krishna Rachakonda
Michael E. Gernaey
18
Super User 2025 Season 1
stampcoin
14
Churchy
12