Pascal

Moderators: None (Apply to moderate this forum)
Number of threads: 4095
Number of posts: 14004

This Forum Only
Post New Thread
Single Post View       Linear View       Threaded View      f

Report
In need of a Pascal script for an installer Posted by MrRadicalEd on 12 Feb 2005 at 2:28 PM
This message was edited by MrRadicalEd at 2005-2-12 14:32:55

I'm currently writing an installer script with Inno Setup that can use Pascal scripts for more functionality, but isn't required to actually make a decent installer. Anyway I had run in to a problem that requires a Pascal script, and while I am highly interested in learning Pascal I am actually focused on getting this installer completed to get this side project out the door.

In my installer script file I have a line like this:
Source: C:\MFCMproject\Game Directories\counter-strike\cstrike\MFCM\mfcm.cfg; DestDir: {reg:HKCU\SOFTWARE\Valve\Steam,ModInstallPath}\counter-strike\cstrike\MFCM

The source file's destination directory is read from an existing registry entry. The problem is that the path read from the registry key is too long and an extra directory needs to be removed at the end.

the entry ModInstallPath is "c:\program files\valve\steam\steamapps\email@address.net\half-life"

and needs to look like:
"c:\program files\valve\steam\steamapps\email@address.net"

The way Pascal code is inserted in to the installer script is by placing Open Bracket"["Code"]"Close Bracket in the script and using the constant {code:...} where you need to use the function

so instead of {reg:HKxx...} it would be {code:function...} The function being the script needed.

Help with this matter would be very greatly appreciated and would installer help would be included in the credits
Thread Tree
MrRadicalEd In need of a Pascal script for an installer on 12 Feb 2005 at 2:28 PM
zibadian Re: In need of a Pascal script for an installer on 13 Feb 2005 at 12:13 AM
MrRadicalEd Re: In need of a Pascal script for an installer on 13 Feb 2005 at 8:21 AM
MrRadicalEd Re: In need of a Pascal script for an installer on 13 Feb 2005 at 8:23 AM
zibadian Re: In need of a Pascal script for an installer on 13 Feb 2005 at 8:26 AM



 

Recent Jobs

Official Programmer's Heaven Blogs
Web Hosting | Browser and Social Games | Gadgets

Popular resources on Programmersheaven.com
Assembly | Basic | C | C# | C++ | Delphi | Flash | Java | JavaScript | Pascal | Perl | PHP | Python | Ruby | Visual Basic
© Copyright 2011 Programmersheaven.com - All rights reserved.
Reproduction in whole or in part, in any form or medium without express written permission is prohibited.
Violators of this policy may be subject to legal action. Please read our Terms Of Use and Privacy Statement for more information.
Operated by CommunityHeaven, a BootstrapLabs company.