January 12, 200719 yr Commercial Member i need some help with the 4.3 install i'm makingjd JD Read my blog
January 13, 200719 yr Author Commercial Member in a new version of setup, i'm getting the path to fs9 and fsx either by the registry, if it isn't in the registry, i'm making the user browse to the fs9 and/or fsx directory.but once i have the fs9 directory, i need to know it again (once for fsuipc in modules, and once for makerwys). i can't figure out how to keep the path in a variable after the first call to the section, so the user is asked twice for the same information.it's something probably simple, i just don't know pascal, for one thing.jd JD Read my blog
January 14, 200719 yr Author Commercial Member it's just for the duration of the install that i need that variable/value handyboth file and registry seemed overkilljd JD Read my blog
January 14, 200719 yr You can set an environment variable that is only set for the duration of your process when you process stops the variable goes away.
January 14, 200719 yr Author Commercial Member i thought about doing that exact thing, but i couldn't find the inno setup function/command/instruction to accomplish thatjd JD Read my blog
January 15, 200719 yr This should do what you want...#define MyAppName "My Program" ; define variablewhere 'My Program' is the path to FS that you want to keep.define directiveSyntaxdefine-directive: default-visibility-set: (define | :) private | protected | public variable-definition: (define | :) [private | protected | public] [[ ]] [[=] ] macro-definition: (define | :) [private | protected | public] ( [] ) formal-macro-args: [, ]... formal-macro-arg: | by-val-arg: [] [= ] by-ref-arg: [] * type-id: any | int | str | func DescriptionThe first syntax of the define directive sets the default visibility of further variable and macro definitions in this file.If no visibility declaration occurs in a file, public visibility is assumed by default.The second syntax defines a variable named ident, or assigns a value to an element of an array named ident. If none of the public, protected, or private keywords are specified, default visibility is assumed which is set by the first syntax of define directive.The third syntax defines a macro named ident. When defining a macro there must be no whitespace between macro name and opening parenthesis, otherwise it will be treated as variable declaration.Examples#define MyAppName "My Program" ; define variable#define MyAppVer GetFileVersion("MyProg.exe") ; define variable#define MyArray[0] 15 ; assign a value to an array element#define Multiply(int A, int B = 10) A * B ; define macro
Create an account or sign in to comment