Two string concatenation

I have a task where i have three variable such as Key,Username and date. I am automating the attachment download according to the given subject line. My task is that i need to download the document and save it with the senders username and date of sent in a folder which should be named with the name that is in subject line. To be more clear i will put an example where
key = Java developer, Username=“soumisoumiya”,date=18jul2019
I should download the attachment which should be renamed as soumisoumiya18jul2019 and should save in a folder named as Java developer.
First thing i should remove the double quotes in the username for that i used the following functions
username.replace(" “, “”)
Split(username.Tostring(),”<")(0).Remove(username.Length-1 ).Trim
Split(username.Tostring(),"<")(0).Replace(" " , “”).Trim
but nothing works
and to rename the file i had given as
this function creates the folder in the name that key has but i need to rename the document name too i dont know how to achieve it.
I also tried move file activity but it does not works fine.
Can any one help me…

Thanks and Regards
Soumiya S

Hello Soumiya

So for the first part you can use Matches with \w+ pattern to select just the words without the double quotes.

Somyua.xaml (5.0 KB)

And for the second part, I don’t know if I understood well, but you can use Invoke Method > Move to move the saved attachment.

I will send you some example XAML file then you use it in your scenario:

EmailAttachment.xaml (11.0 KB)

In this flow I download the Attachment then save it in different location (you can customize this to your example)

1 Like