View Full Version : Installer for a GML file
Rob H
June 19th, 2004, 03:56 PM
I'm writing an installer for GML file and LUA script using InnoSetup. I've found the message about locating the Girder directory which was very helpful, what I am wondering is whether it is possible to query Girder to see if an earlier version of the GML file has been installed?
Also, can I get Girder to import the GML file from within the installer, or do I need to tell the user how to do the import?
I assume that this would require OLE Automation - I'm new to InnoSetup and I don't think that it includes full COM support.
Thanks
Promixis
June 19th, 2004, 04:31 PM
Rah, you can have INNO install the GML and set Girder to automatically load it on next startup. Here is the code for Lua Windows Function Plugin
[code]; Script generated by the Inno Setup Script Wizard.
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!
[Setup]
AppName=Girder Lua System Functions Plugin
AppVerName=Lua System Function 1.1.0.0.
AppPublisher=Promixis
AppPublisherURL=http://www.promixis.com
AppSupportURL=http://www.promixis.com
AppUpdatesURL=http://www.promixis.com
DefaultDirName={code:GetGirderDir}
DisableDirPage=yes
DisableProgramGroupPage=yes
LicenseFile=Z:\Development\Inno Installation\Common Files\Girder Plugin End User License Agreement.rtf
InfoBeforeFile=Z:\Development\Inno Installation\LSysFunc\Lua System Functions Intro.rtf
Compression=lzma
SolidCompression=yes
[Files]
Source: Lua System Functions.pdf; DestDir: {app}\help; Flags: ignoreversion
Source: Z:\Development\Inno Installation\LSysFunc\LSysFunc.GML; DestDir: {app}; Flags: ignoreversion
Source: Z:\Development\Inno Installation\LSysFunc\LSysFunc Constants.lua; DestDir: {app}; Flags: ignoreversion
Source: LSysFunc.dll; DestDir: {app}\plugins; Flags: ignoreversion
; NOTE: Don't use "Flags: ignoreversion" on any shared system files
[code]
function GetGirderDir(Default: String): String;
var
s : string;
begin
if ( RegQueryStringValue(HKEY_LOCAL_MACHINE,'SOFTWARE\g irder3','Executable',s) = TRUE ) then
begin
Result := ExtractFileDir(s)+'\';
end
else
begin
Result:='c:\program files\girder';
end;
end;
[Run]
Filename: {app}\help\Lua System Functions.pdf; Description: Plugin Documentation; Flags: nowait postinstall skipifsilent shellexec
Filename: {app}\girder.exe; Parameters: lsysfunc.gml; Description: Girder Example; Flags: nowait postinstall skipifsilent
[Registry]
Root: HKLM; Subkey: software\girder3\plugins; ValueType: dword; ValueName: 155; ValueData: 1[/code]
Rob H
June 19th, 2004, 04:57 PM
Thanks Mike - does that do the equivalent of an import? From a fairly cursory inspection it looks as though it just loads the GML file rather than importing it into the current default.
If it does do an import then presumably I can save the normal autoloaded file beforehand from HKLM\Software\Girder3\Autoload
Is there a list of command-line switches for Girder.exe somewhere?
Promixis
June 19th, 2004, 06:35 PM
No, it does not do an import. I don't think there is a way of doing that from the installer.
Rob H
June 20th, 2004, 12:37 AM
Ah, pity. That's one for the wishlist then
Ron
June 21st, 2004, 10:04 AM
Added to 4.0 wishlist.
Powered by vBulletin® Version 4.1.8 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.