; Script generated by the Inno Setup Script Wizard. ; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES! [Setup] ; NOTE: The value of AppId uniquely identifies this application. ; Do not use the same AppId value in installers for other applications. ; (To generate a new GUID, click Tools | Generate GUID inside the IDE.) AppId={{9219963B-37EC-45F5-920E-3670B9A08DB3} AppName=Ogre exporter for Sketchup AppVersion=Ogre exporter for Google Sketchup 1.3.6 ;AppVerName=Ogre exporter for Google Sketchup 1.3.6 AppPublisher= AppPublisherURL=http://www.openspace3d.com AppSupportURL=http://www.openspace3d.com AppUpdatesURL=http://www.openspace3d.com DefaultDirName={code:GetSketchupDir} DefaultGroupName=Ogre exporter for Sketchup OutputDir=release OutputBaseFilename=Ogre_sketchup SetupIconFile= Compression=lzma SolidCompression=true UninstallDisplayIcon= InternalCompressLevel=max VersionInfoVersion=1.3.6 VersionInfoCompany=I-Maginer VersionInfoDescription=Ogre exporter for Google Sketchup VersionInfoCopyright=I-Maginer 2015 MinVersion=0,5.01.2600 AppCopyright=I-Maginer 2015 DisableProgramGroupPage=false UsePreviousAppDir=false AppendDefaultGroupName=true InfoBeforeFile= DirExistsWarning=no AppendDefaultDirName=False [Languages] Name: english; MessagesFile: compiler:Default.isl Name: french; MessagesFile: compiler:Languages\French.isl [Tasks] [Files] ; NOTE: Don't use "Flags: ignoreversion" on any shared system files Source: files\*; DestDir: {app}\; Flags: ignoreversion recursesubdirs createallsubdirs overwritereadonly replacesameversion; Excludes: .svn [Icons] Name: {group}\{cm:UninstallProgram,Ogre exporter for Sketchup}; Filename: {uninstallexe} [Run] [Registry] [CustomMessages] [Code] /////////////////////////////// // Sketchup install directory function GetSketchupDir(Default: String): String; var Value: String; begin if RegQueryStringValue(HKLM, 'SOFTWARE\SketchUp\SketchUp 2016\InstallLocation', '', Value) then begin Result := Value; end else if RegQueryStringValue(HKLM, 'SOFTWARE\SketchUp\SketchUp 2015\InstallLocation', '', Value) then begin Result := Value; end else if RegQueryStringValue(HKLM, 'SOFTWARE\Wow6432Node\SketchUp\SketchUp 2015\InstallLocation', '', Value) then begin Result := Value; end if RegQueryStringValue(HKLM, 'SOFTWARE\SketchUp\SketchUp 2014\InstallLocation', '', Value) then begin Result := Value; end else if RegQueryStringValue(HKLM, 'SOFTWARE\Wow6432Node\SketchUp\SketchUp 2014\InstallLocation', '', Value) then begin Result := Value; end else if RegQueryStringValue(HKLM, 'SOFTWARE\SketchUp\SketchUp 2013\InstallLocation', '', Value) then begin Result := Value; end else if RegQueryStringValue(HKLM, 'SOFTWARE\Wow6432Node\SketchUp\SketchUp 2013\InstallLocation', '', Value) then begin Result := Value; end else if RegQueryStringValue(HKLM, 'SOFTWARE\Google\Google Sketchup 8\InstallLocation', '', Value) then begin Result := Value; end else if RegQueryStringValue(HKLM, 'SOFTWARE\Wow6432Node\Google\Google Sketchup 8\InstallLocation', '', Value) then begin Result := Value; end else if RegQueryStringValue(HKLM, 'SOFTWARE\Google\Google Sketchup 7\InstallLocation', '', Value) then begin Result := Value; end else if RegQueryStringValue(HKLM, 'SOFTWARE\Wow6432Node\Google\Google Sketchup 7\InstallLocation', '', Value) then begin Result := Value; end else if RegQueryStringValue(HKLM, 'SOFTWARE\Google\Google Sketchup 6\InstallLocation', '', Value) then begin RegQueryStringValue(HKLM, 'SOFTWARE\Wow6432Node\Google\Google Sketchup 6\InstallLocation', '', Value) end; if Value = '' then begin Value:= 'C:\Program Files\SketchUp\SketchUp 2016'; end //MsgBox('Value is "' + Value + '"', mbInformation, MB_OK); Result := Value; end;