How to take screenshot in PiP mode using Take Screenshot / Invoke VB.Net activity

How to take screenshot in PiP mode using Take Screenshot activity.

I used Classic version of Take Screenshot and got an error. In Modern version I didnt get any error however the screenshot was not captured/saved in the destination folder.

Also, please let me know if there is any other alternative way like VBA / VB.net code to achieve the same ?

Can someone help pls

If you are running PIP mode in windows option - This is a known limitation. BOT won’t be able to take screenshot / any hardware events

Try changing the mode to session while running PIP and see if it is working fine or not

Go to Project Settings and change PIP Type

Hello,

Thanks for your response.

However as per organization policy, the PiP type option is disabled for us…

The current studio version what we use is 22.4.1

Hi Avinesh,

Try this it will work

If you prefer VBA, you can use the following code:
Sub TakeScreenshot()
Dim ws As Worksheet
Set ws = ThisWorkbook.Sheets(“Sheet1”)
ws.Range(“A1”).Select
Application.SendKeys “(%{1068})”
Application.SendKeys “{PRTSC}”
ws.Paste
ws.Shapes(ws.Shapes.Count).Name = “Screenshot”
ws.Shapes(“Screenshot”).Copy
ws.Pictures.Paste
ws.Shapes(“Screenshot”).Delete
End Sub


This VBA code takes a screenshot and pastes it into the specified Path, You can pass an argument for Path

Thanks
Vineet

.

What is the default value selected in the PIP Type ??

Also please refer below links as well to understand more on the limitations and comparison

Assistant - Technology Comparison

Hello @Avinesh_Ramanathan ,
please go through the below Xaml file, it works!

Save_Image_From_Clipboard.xaml (8.7 KB)

Do mark it as solution if it helps you.
Cheers!

HI,

Please find the details in attachment

HI,

Can you please explain how to save the screenshot image using this VBA code

May i know the version of Studio and Assistance?

HI, I am unable to open this workflow. It shows document is invalid

Studio version is 22.4.1

Here’s the zip of full folder,

TIP - If you see error in assign activity, just assign same value below again and delete above assign activity.

Save_IMG_From_Clipboard.zip (3.4 KB)

Thanks for sharing. I am getting below error, though i clicked on Repair Dependencies

Ok great,
Also you need to change path of save image activity according to your requirement,
Let me know if it works.

@Avinesh_Ramanathan ,
please check you have downloaded required packages like UiPath.uiautomation.activities

cheers!

PLease confirm UiPath.System.Activities is installed properly. Not the runtime activity