Indigo Rose Software

Go Back   Indigo Rose Software Forums > Setup Factory 8.0 > Setup Factory 8.0 Examples

Reply
 
Thread Tools Display Modes
  #1  
Old 11-15-2008
jassing's Avatar
jassing jassing is offline
Indigo Rose Customer
 
Join Date: Jan 2001
Location: Anderson Island, WA, USA
Posts: 1,899
Display File Description in the "While Installing" progress bar screen

I had a client that wanted to display the file's description in the progress bar screen (while installing). Someone told him he couldn't do it.

ie: "Application Help File" instead of
"c:\program files\My Application\docs\Help.chm"

He had already done the "hard part" of putting the descriptions in for each of the files he wanted to display the description for.

I opened up a few LUA files, as I knew I had saved the code from other projects; and sent it off...

He was so impressed; that I now guess it isn't as common as I thought it was...

Here's what I do:

In the "While Installing" you need to edit the "On Preload" and "on progress" actions.

On Preload
Code:
tFileList = SetupData.GetFileList(ARCHIVE_LIST);
On Progress
Code:
if e_Stage == INSTALL_STAGE_INSTALLING_FILES then
	local nIndex;
	local tPropTable;

	for nIndex, tPropTable in tFileList do	
		-- Goofy Bit
		local cFile = SessionVar.Expand( String.Replace( tPropTable.Destination,"\\","\\\\") ).."\\"..tPropTable.FileName;
		cFile = String.Replace(cFile,"\\\\","\\");
		if String.Lower( cFile ) == String.Lower( e_CurrentItemText ) then
			-- We have a match!  Show the description instead, but only IF there's a description
			if String.Length( tPropTable.FileDescription ) > 0 then
	  		e_CurrentItemText = tPropTable.FileDescription;
	  	end
	  	break;
	  end
	end
end
The goofy bit :
Code:
local cFile = SessionVar.Expand( String.Replace( tPropTable.Destination,"\\","\\\\") ).."\\"..tPropTable.FileName;
cFile = String.Replace(cFile,"\\\\","\\");
I'm not sure that's still needed, IR may have fixed it; but at one point, you wouldn't always get the right name, sometimes there'd be a %AppFolder% in with it; so you had to use SessionVar.Expand(). However, with only one '\' it screwed it up; so you have to be sure there's doubles in there; the reuslt is usually "good" but sometimes, there remains a double; so you need to remvoe them, once you expand the sessionvar. Goofy, I know; but it was my experience; and that was the work around....

So now you can do anything you want; display just the file name instead of the path; display the size along side the file name, etc...
__________________
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
only this please - progress bar start when the file start deleting . melissa AutoPlay Media Studio 7.5 Discussion 1 06-08-2008 08:36 AM
Progress screen -- changing bar colour jassing Setup Factory 7.0 Discussion 0 02-13-2007 02:07 PM
http://yourfilelink.com - 50MB max upload, free! Intrigued General Chat 14 09-26-2006 09:44 AM
Error 3038: Could not seek in compressed file Rikard Setup Factory 7.0 Discussion 2 05-25-2006 12:55 PM
Extract a zip file with a progress bar GhoXt AutoPlay Media Studio 6.0 0 05-22-2006 09:06 AM


All times are GMT -6. The time now is 02:00 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Copyright © 2000 - 2009 Indigo Rose Corporation. All rights reserved.
Indigo Rose Software