PDA

View Full Version : Load File (For License Screen)


BigGuy
08-21-2008, 10:17 AM
I would like to write my License File in a text editior with %Variables% then when the screen is shown it will Load the file then convert the variables that are already created, like %CompanyName%, %ProductName%, %ProductVer% to name a few. Currently it does not convert the variables.

I can do this by creating 3 variables, to create 3 paragraphs.
I set the 3 %Variables% in the On Startup and it works when the License screen come up, but then it is not a text file.

Another thing would be ok is to write the text and variables on the screen then have setup factory 8 save this text and the variable contense to the users %AppFolder% directory after installation so the user will have a final agreenment with all the variable information. It would be nice if SUF8 would place a selector on the build screen to automaticly create a text file of the screen text.

Any help on creating the text file from the screen and or the %Licensetxt1%, %Licensetxt2% and %Licensetxt3% that works?

jassing
08-21-2008, 11:39 AM
If I'm following you -- you have a text file that contains session variables.

You want to display this text file in the license screen, with session variables expanded.

if so, how about somethign like this: (Air Code)

local cLicenseTextRaw = TextFile.ReadToString( MyLicenseFile );
local cLicenseTextExpanded = SessionVar.Expand( cLicenseTextRaw );
TextFile.WriteFromString( MyLicenseFile, cLicenseTextExpanbded, false);