How to get data from RDP using UiPath?

Hi Everyone,

I want to create a robot to automate on remote application using UiPath Studio.

Task Scenario-

  1. Needs to take a login for servers and go to start button and right click then select computer Management.

  2. Then go to Local users and groups Tab.

  3. Then drop down the local users and groups then click on Users tab and then extract the data and save it into an excel sheet and now it should compare the users name against the IP and if anything has deleted then update the status in the sheet as deleted and if anything has added then it needs to update the status as changes.

  4. I have 60 servers and each server’s data needs to be extracted and compare with the original data which are present in excel file and then update the status as per comparison.

  5. each server has minimum 5 user name and max 10-15.

I would be grateful to get a solution on this.

Thank You !


Can anyone please reply on this?


I think this can be done using Powershell also no need to go to Computer Management & all.
You can use the Invoke Power Shell Activity

& Use this command in powershell which will give all the user info of Users group

Get-LocalGroupMember Users

You can use the output of the activity Invoke Power Shell to compare with your existing list.

For Ref- How to Manage Local Users and Groups using PowerShell (

Hope this helps :slight_smile:

1 Like

In general you would use image based UI automation, or Computer Vision (preferred) to navigate around in the RDP window.

However, there is surely a better way to get this info from your devices. I suggest talking to your network administrators to find out what tools they use, and what other options they can suggest. Remoting into 60 servers to get this information is IMO not a very good design.



you can do it very easy using PowerShell without needing to connect to a RDP session like this


CommandText field

# Create a PSCredential object using the secure strings
$credential = New-Object System.Management.Automation.PSCredential($userName, $securePassword)

# Get local user accounts on the remote machine
$LocalUsersArray = Get-WmiObject -Class Win32_UserAccount -ComputerName $computerName -Credential $credential | Select-Object -ExpandProperty Name

the target server needs to be accessible on the network, and the user being used inside the script needs permission to list the users.


Hi @rikulsilva,

I have tried the steps below however getting an error. Could you please check it what I am doing wrong into this-


don’t forget to mark ‘IsScript’ in properties:

Hi @pikorpa,

Thank you for the reply however it didn’t work. I have marked ‘IsScript’ in properties still getting the same error.


Hi @AJ_Ask,

I have not got a solution yet, can you please reply on this?

Actually, I work on VM so any other way to do this as I have tried with Invoke PowerShell activity however it didn’t work.

I have put in command text- "Get-LocalUser and getting an error here only.



You will get local users for each server
from the vm machine that you are running project, right ?

Hi @rikulsilva

You will get local users for each server
from the vm machine that you are running project, right ?- Yes

Getting same error. Looks like it is because “The Microsoft.PowerShell.LocalAccounts module is not available in 32-bit PowerShell on a 64-bit system.”


You could overcome this limitation by changing “Execution Mode” propperty to one of 64bit PS versions. This propperty is however available only in 23.12.0-preview version of System activities.




The UiPath.System.Activities 23.12-0-preview, the PowerShell Activity has the option to choose which version you want to use.

The below sample was build with Legacy compatibility (3.1 KB)


I am having 21.10.3 version so please guide for this version

Happy automation.