How to install to Vista or XP

Started by innervations, September 17, 2008, 12:51:29 PM

Previous topic - Next topic

innervations


Randem

Try DestDir: {Code:GetAppFolder|AppVerName}
 
From Inno Setup Help Documentation:
 
The Pascal script can contain several functions which are called when Setup wants to know the value of a scripted {code:...} constant. The called function must have 1 String parameter named Param, and must return a String value.
 
The syntax of a {code:...} constant is: {code:FunctionName|Param}
 
FunctionName specifies the name of the Pascal script function.  
Param specifies the string parameter to pass to the function. If you omit Param, an empty string will be passed.  
If you wish to include a comma, vertical bar (|), or closing brace (}) inside the constant, you must escape it via %-encoding. Replace the character with a % character, followed by its two-digit hex code. A comma is ,, a vertical bar is %7c, and a closing brace is %7d. If you want to include an actual % character, use %25.  
Param may include constants. Note that you do not need to escape the closing brace of a constant as described above; that is only necessary when the closing brace is used elsewhere.  

innervations

Thanks. Found the template and added it in but how do I call it if I want to create a folder and put the application configuration settings (text file) in the correct folder for XP or Vista? I tried the following but does not work.
 
Source: C:UsersRob NewtonDocumentsProgrammingBallistic System 2005 VersionBMSConfig.txt; DestDir: GetAppFolder(AppVerName); Flags:  restartreplace ignoreversion;

Randem

Sorry, We changed the template from Vista to the Legacy. All you really need to do is just select Add on the Templates tab to get to the templates folder. If you add the template then double click on it it will open for editing if you want to edit it.

innervations

Thanks for the speedy response. Found the Vista template in the folder C:Program Filesrandem systemsInnoScriptInnoScript 9Templates
 
But it only contains the following text:
 
[Comments]
 
 Template Processing first character indicators usage.
 
         No Indicator      Attempt replacement if cannot replace then add the line
          Plus Sign      Force addition of template line into script (no attempted replacement).
  ;      Semi-colon      Add line as a comment only. (No attempted replacement).
  -      Minus Sign      Delete the line. (No attempted replacement).
  &      Ampersand      Comment the line. (No attempted replacement).
 
Am I missing something?  
Thanks for the support.

Randem

Check the templates. There is a Vista template especially for that.

innervations

I have read the excellent instructions on installing program data files to C:UsersPublicYourAppName for Vista to avoid the security issues with needing to read and write to these files without administrator access. My question is how can I also detect the OS with InnoScript and place these files correctly for either Vista or XP?
 
Thanks for any assistance.