Out of the blue I’m started experiencing an error inside an assign activity which assign the value of a New StreamReader(filePathStringVariable) to a Streamreader variable. The error message:
Main has thrown an exception
Message: Job RoboView stopped due to unexpected process termination!
Exception Type: Exception
System.Exception: Job RoboView stopped due to unexpected process termination!
Right now it occurs all the time I run the robot (both from Studio and also from Orchestrator). I’ve also tested numerous pdf files (different page numbers, different content) but I’m not able to wrap my head around it.
There weren’t any relevant operations done on the server in the meanwhile (checked with my company internal IT department).
StreamReader is a TextReader, it reads .txt file, so it is dubious to me it should read from a pdf file. Can you try Read Pdf Text activity and Read Pdf with Ocr (you need to install UiPath.Pdf.Activities packages)
I choosed StreamReader because I need to count and loop through the pages of the pdf file. Here below a screenshot of the next activities in the workflow:
As a matter of fact, UiPath.Pdf.Activities package has a lot of activities that allows you to read, merge, split, extract and so on, so you might want to check it out