Batch File to Detect if Application Installed


  1. Posts : 48
    Windows 8.1
       #1

    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 Computer


  2. Posts : 2,468
    Windows 7 Ultimate x64
       #2

    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 Computer


  3. Posts : 48
    Windows 8.1
    Thread Starter
       #3

    Ok, well thank you.
      My Computer


 

  Related Discussions
Our Sites
Site Links
About 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 22:50.
Find Us