How to solve "UiPath Robot cannot be installed when an existing UiPath Studio installation is present"?

How to Solve "UiPath Robot cannot be installed when an existing UiPath Studio installation is present" when upgrading the Robot?

Issue description:

When attempting to upgrade the Robot, the error "UiPath Robot cannot be installed when an existing UiPath Studio installation is present." appears:

Resolution:

Starting with the 23.10 release, there are separate installers for Studio and Robot, UiPathStudio.msi and UiPathRobot.msi, respectively.

This issue can happen when trying to upgrade the UiPath Robot v23.10 or higher on a machine where Studio is also installed, using the UiPathRobot.msi.

Studio and Robot, if on the same machine, must be updated at the same time using the UiPathStudio.msi installer, regardless of whether the robot was deployed in user or service mode.

In order to resolve the issue, use the UiPathStudio.msi instead to update both Studio and Robot at the same time.