Download an image using Openspan / Pega Automations
I'm making an automation that would require displaying an image in a UI, which is taken from a website. Is there a way to download an image so that I can then set the filepath for that image in my picturebox?
**Updated by Moderator: Lochan. Removed user added Ask the Expert tag. Apologies for confusion, shouldn't have been an end-user option.
***Updated by moderator: Marissa to update categories***
**Moderation Team has archived post**
This post has been archived for educational purposes. Contents and links will no longer be updated. If you have the same/similar question, please write a new post.
When using a windows form in your Robotic solution, you have the option to add a picture box to the form through the tool box. This picturebox component contains an image location property that accetps file paths and web location addresses as a means to dispaly specific images within the picture box. I have attached a screenshot to illiustrate the component and property.
However, there is another alternative to displaying and maintaing content with your Robotics solution. The alternative is Agile Desktop. Agile Desktop, provides you with the ability to inhouse and display custom images for your solution. It also provides a seameless means for agents to interact with your solution's automation through it's dashboard UI. Below is a link that goes into greater detail of how to use Agile Desktop.
Sorry, I should have been clearer. The image I would be displaying is a dynamic image generated by a website - it is a pie chart that displays statistics, so it will be different every time. If I could download it and set the title of the image, I could then set my windows form to display an image from a file path, with the image name. Is there any way I can achieve this at all?
Hey Ryan, I have the same need and a team mate of mine has found a script to grab the entire desktop and save it as a PNG. Below is the essence of the script. I'm going to start playing around to see if I can get it focused on a particular window or area of a window. I'll let you know how I do getting it refined or if you can repost an updates I'd appreciate it!
Bitmap screenshot = new Bitmap(SystemInformation.VirtualScreen.Width,