Here is a quick tip for you, if you ever want to know the uninstall string to remove an Exchange Server, you can run a simple command to get the UninstallString from the Windows Registry, the command is as follows:
Get-ExchangeUninstallKey
This command will produce the output below:
![Exchange 2019:- find the registry key to uninstall exchange from the command line Exchange 2019:- find the registry key to uninstall exchange from the command line](https://everything-powershell.com/wp-content/uploads/2023/11/image-1.png)
If we head over to the registry we can see the same information, PowerShell just makes it easier
![Exchange 2019:- find the registry key to uninstall exchange from the command line Exchange 2019:- find the registry key to uninstall exchange from the command line](https://everything-powershell.com/wp-content/uploads/2023/11/image-2-1024x552.png)
Hope it helps.