Go Back   TechArena Community > Software > Software Development
Become a Member!
Forgot your username/password?
Tags Active Topics RSS Search Mark Forums Read SiteMap

Tags: , ,

Sponsored Links


Need a batch file checking for installation of software

Software Development


Reply
 
Thread Tools Search this Thread
  #1  
Old 18-07-2012
Member
 
Join Date: May 2012
Posts: 55
Need a batch file checking for installation of software

Sponsored Links
I am have created an application for storing the data of an organization into an database. Now I want to create an installer for my application. I know Visual Studio has in-built package to show the installation of an application. But I want to create such a program that will help me create my own installer for this application. I don’t want any user to get the license and other details like selecting location to install thing while installation. Everything will be pre-designed and all user will have to do is to click and install the software. Can anyone help me create it in Visual Studio by help of a batch file? Does anybody know anything about it?

Reply With Quote
  #2  
Old 18-07-2012
Member
 
Join Date: May 2011
Posts: 95
Re: Need a batch file checking for installation of software

After you have developed a software, many processes other than installation have to be applied on it. The MWI (Microsoft Windows Installer) package that is available in Visual Studio has many features embedded in it. It has features to install and uninstall the software. If the software is already installed in the computer and the user tries to again install it, then a notification should be given that software is already installed. Do you want to uninstall previous software and then install it again or do you want to repair it notification. This process needs to verify all the existing softwares in the computer. Also the installer has to confirm if all the resources needed for its working is available or not. So when you make the installer for your application you have to give all these features too.
Reply With Quote
  #3  
Old 19-07-2012
Shreevats's Avatar
Member
 
Join Date: May 2009
Posts: 514
Re: Need a batch file checking for installation of software

I have tried making the installer for an application from scratch and I succeeded in creating it. The batch file that I created can now install and uninstall an application easily. Though it doesn’t provide massive options and functionality, it will do the basic functionality of a Microsoft Windows Installer (MSI). You just have to use the WMI class Win32_Product along with the Uninstall method. The code for following operation that I got working is,
Code:
strComputer = "."
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\\" _
& strComputer & "\root\cimv2")
Set colSoftware = objWMIService.ExecQuery _
("Select * from Win32_Product " _
& "Where Name = 'Personnel database'")
For Each objSoftware in colSoftware
objSoftware.Uninstall()
Next
Try it out and see if it works for you or not. This is just the basic syntax of the batch file that I created. You will need to alter it according to your need.
Reply With Quote
  #4  
Old 19-07-2012
Member
 
Join Date: May 2009
Posts: 489
Re: Need a batch file checking for installation of software

To create an installer using the batch file to have more functionality to detect existence of softwares and files in a computer. Also to have features like checking the version of the operating system and other hardware that are required for working of the software, you can use the codes given on official website of Microsoft. You will find all your required batch files here using which you can create an installer for your application. You will need to copy these codes in the .vbs file of your project and then change it according to the modules of your application present in your project.
Reply With Quote
Reply

  TechArena Community > Software > Software Development


Thread Tools Search this Thread
Search this Thread:

Advanced Search


Similar Threads for: "Need a batch file checking for installation of software"
Thread Thread Starter Forum Replies Last Post
automating installation using batch file tush9876 Software Development 1 01-05-2012 01:28 AM
un-checking toolbar at Zonealarm 10.1.065.000 installation is making no effect MarDaA Networking & Security 3 17-02-2012 01:56 PM
Batch File for doing the Silent Installation. hatred Software Development 4 27-01-2010 08:42 PM
Checking Windows Media Player plugin installation Dharmesh Arora Windows Software 3 27-06-2009 06:18 PM
Is there a batch file to install software bigboy Windows Software 3 06-05-2009 11:20 PM


All times are GMT +5.5. The time now is 11:27 AM.