Start Process open PDF

Hey Community,

we have following Problem, i hope you can help us.

We extract a file name out of an email
By using the activity “Start process” we want to combine the path of the folder with the file name.
Apparently while combining the two parts in one string variable UIPath will always set a line break between the folder path and the file name.

E-Mail extraction: DAS-HKCNJ.zip = Dataname
PDF File Name: DAS-HKCNJ.pdf=DataPDF
Start Process: “C:\Users\Christoph\Documents\UiPath"Dataname+”"+DataPDF

The Log is: C:\Users\Christoph\Documents\UiPath\DAS-HKCNJ.zip
DAS-HKCNJ.pdf

Thank you for your help.

Christoph

1 Like

Hey @christoph.schwetje

You mean to say the PDF is present inside zip ?

Thanks
#nK

okay i see my problem… my regex makes a linebreak.

(?<=identifications/).* Anyone know who i can say without linebreak?

Thanks :slight_smile:

Hey @christoph.schwetje

Sorry the context is not clear.

Kindly explain what you are doing to get the path ?

Thanks
#nK

sorry…

i have an email. In the E-Mail is a URL: for example like this:

https://google.de/k4587/identifications/DAS-HKCNJ.zip

Behind the url is a new linebreak. First i thought i can find “DAS-HKCNJ.zip” with (?<=identifications/).* but i dont know how i can search withouth the linebreak…

I hope you can understand me now…

Christoph

1 Like

Hey @christoph.schwetje

How are you then retrieving that please ?

Or please show us the email body !

Thanks
#nK

@christoph.schwetje

  • I see there were two file names(DAS-HKCNJ.zip, DAS-HKCNJ.pdf) in the path. Is this how you should do ?? If this is the case bot might run into issues. It should be either zip or pdf.

  • Also, after you extract the data make sure you remove the spaces of that variables using Trim

C:\Users\Christoph\Documents\UiPath\DAS-HKCNJ.zip
DAS-HKCNJ.pdf
  • The complete file path should be like
C:\Users\Christoph\Documents\UiPath\DAS-HKCNJ\DAS-HKCNJ.pdf

Then the bot can open pdf without any issues

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