Windows 7 Forums
Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.



Windows 7: Batch File to Detect if Application Installed

11 Apr 2013   #1

Windows 7 Ultimate
 
 
Batch File to Detect if Application Installed

Hey everyone! I'm making a batch file for a computer repair company I'm with and I'm trying to automate as much stuff as possible and speed things up. As of this moment, I got all the major components of a batch file that retrieves information about the computer (Manufacturer, Model #, Serial #, etc.) then it opens up our site and logs that information in the site's database for the user's later review. Now, our site is programmed for netscape based browsers (Opera, FireFox, Chrome) and has some serious issues with Internet Explorer. So what I'm trying to find out is how do I make a batch file detect if a netscape based browser is installed and then open the site up in that browser? Any alternatives to this would be nice, we're trying not to completely redesign the website but will if it has to be done.

My System SpecsSystem Spec
.

11 Apr 2013   #2

Windows 7 Ultimate x64
 
 

I can think of 2 quick solutions, and neither are 100% reliable really.
One would be to check for the existence of the folder in program files, using an IF EXIST c:\program files\opera\nul............ and assuming it will be there. However it has problems if the user installed to a non standard location and you'll have to watch out for 32/64 bits versions which go to different folders.
Another way would be to check for the existence of the registry key un HKLM\Software\Opera, using REG QUERY command (check the actual key created beforehand, I'm just inventing here, but the idea is that). This also fails when the user is using the portable installations of browsers, which are registry-free.

In the long run, the only sure method would be to fix the site to make it work in IE. It's really common that non-IE browsers run the sites as they should, yet IE has problems frequently due to being standards-incompatible. While it's more work, I would ask a web developer to do the fix and workaround those IE bugs to make the site work properly everywhere. It's a very common problem unfortunately.
My System SpecsSystem Spec
16 Apr 2013   #3

Windows 7 Ultimate
 
 

Ok, well thank you.
My System SpecsSystem Spec
.


Reply

 Batch File to Detect if Application Installed





Thread Tools




Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 08:18 AM.
Twitter Facebook Google+



Windows 7 Forums

Seven Forums Android App Seven Forums IOS App
  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33