Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

I have a problem using Wise for Win

Status
Not open for further replies.

NikC

Programmer
Jun 29, 2003
5
0
0
NZ
I have a problem using Wise for Windows Installer someone may be able to help with...

During my installation I want to install multiple copies of a file. The installer will be able to enter the number of copies of the file that they want installed into a dialog text field. The text field will have a property e.g "NUMFILES". I can read the value of this property - But how do I then get Windows Installer to install this number of files?
 
You will need a custom action. If on a machine with IE 4 or better you should be able to use a custom VB/JScript action. If embedded they can easily retrieve the value of the NUMFILES property (Session.Property("NUMFILES")).

If your audience is diverse (don't know if the WSH and FSO objects are available) you can use a C++ dll or (if using Wise Package Studio) a Wise Script Editor. Both of these will allow you to retrieve the property.

Barring that you can write the information to the registry and use a compiled program in the language of your choice as a custom action that runs at the end of the install to copy the files.

IOW, there is no way internal to the Wise Installer technology to accomplish what you want... except... If there are a finite number of files (say 1-10) you could place the files in separate components and give each component a condition of NUMFILES>=X (where x is a number from 1-10).

HtH,

Rob
robschultz@yahoo.com
-Focus on the solution to the problem, not the obstacles in the way.-
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top