Check for windows update

Hi, is there any way to check if any Windows updates are available? some way to check using only code?

1 Like


You can check for available Windows updates using UiPath Studio and activities by following these steps:

  1. Open UiPath Studio and create a new project.
  2. Drag and drop the “Invoke PowerShell” activity from the Activities panel onto the workflow canvas.
  3. In the “CommandText” property of the activity, enter the following PowerShell command: Get-WindowsUpdate
  4. In the “Output” property, select “Text”.
  5. Add a “Message Box” activity and connect it to the “Invoke PowerShell” activity.
  6. In the “Text” property of the “Message Box” activity, enter the following expression: outputVariable.ToString()
  7. Run the workflow.

The “Invoke PowerShell” activity will run the “Get-WindowsUpdate” command in PowerShell, which will return information about available Windows updates. The output will be stored in a variable, which can be displayed in a “Message Box” activity using the expression outputVariable.ToString().

Note: You may need to run UiPath Studio as an administrator to access Windows update information. Additionally, if you encounter any errors, you may need to modify the command or add additional activities to handle errors.

Cheers @tomaz

1 Like

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