JackFlashJI Posted September 20, 2010 Share Posted September 20, 2010 Can someone please provide direction for the following: I would like to check if an application has been installed on a workstation. If the application exists on the workstation, then I would like to uninstall it. Application name is 'XYZ app'. If the application does not exist, then I will simply move on to the next part of my code.... The application may or may not be running, so it is my understanding that I cannot somply check to see if the process exists..... Thanks in advance Link to comment Share on other sites More sharing options...
Varian Posted September 20, 2010 Share Posted September 20, 2010 (edited) "Check if application installed" is pretty broad. The 2 thoughts I have would be do check for the existence of a directory structure (or at minimum search for the executable, but this is time consuming and not always reliable) or check the registry uninstall section for the application. The latter would be the optimum choice, but there may not be an entry depending on the application. There is also a difference between the methods of uninstalling the application depending on the type of install(MSI, Wise, etc.). You could also try to automate running the Add/Remove program applet, but that may be tough depending on the OS version(XP, Vista, Windows 7, etc.) Edited September 20, 2010 by Varian Link to comment Share on other sites More sharing options...
Bert Posted September 20, 2010 Share Posted September 20, 2010 Several things to think about:You can look in the registry to see what is installed. This article will give you some direction on how the registry is involved in this: http://support.microsoft.com/kb/314481Look for specific exe or other file types files in specific folders.Look in startup - This is also listed in the registry.Look at what is in the login script. The Vollatran project My blog: http://www.vollysinterestingshit.com/ Link to comment Share on other sites More sharing options...
JackFlashJI Posted September 20, 2010 Author Share Posted September 20, 2010 Thank you for your replies.... All the systems involved are Windows Server 2003 SP2 booxes. * There are 4 applications that I am working with and they are all setup a little different, so using registry works for some but not all. * Two of them install to the same folder, so using the folder is not optimal because even if the folder is there, that does not mean both are installed. All appear in the "Add/Remove" and I would like to automate that process is possible. This is where I was looking for guidance. Thanks. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now