PDA

View Full Version : Wildcard file sizes



NewsArchive
01-25-2010, 01:44 AM
Ok, you solved my file renaming... any chance of getting wildcard file
size totals? When I use them, as shown in the image, I get 0 for file
size which makes it appear as though nothing was found... and I get
worried easily!<g>

--
Lee White

Enroll Today at http://CWaddons.com

Reports....: http://www.cwaddons.com/products/rpm/
Free Review: http://www.clarionmag.com/cmag/v11/v11n06rpm.html
Faxing.....: http://www.cwaddons.com/products/afe/

NewsArchive
01-25-2010, 01:46 AM
> wildcard file size totals?

After some thought, if possible, I'd like a count of matching files
with the total size. Maybe something like this...

Lee White

NewsArchive
01-25-2010, 01:46 AM
Hi Lee,

>> wildcard file size totals?
>
> After some thought, if possible, I'd like a count of matching files
> with the total size. Maybe something like this...

Unfortunately, this is not possible. In most cases, the values for compiler
variables are set at compile time.

For example, our own project for SetupBuilder images. We are using the very
same .sb7 for all SetupBuilder Editions. The selected edition determines
the "Link to" folder (at compile time).

For Professional Edition: [FILE_POOL] is set to \\Win7-64\corpdata\SB7Pro

For Developer Edition: [FILE_POOL] is set to \\Win7-64\corpdata\SB7Dev

So the value of [FILE_POOL] at "design time" does not mean anything and can
even be confusing or erroneous. And most developers even set the values for
compiler variables programmatically in the script and/or from the command
line.

Something like:

#ifcompvar [SELECTED_EDITION] Equals "Full" Then
#set compiler variable [SOURCE_FOLDER] = "c:\yada\full"
#end

#ifcompvar [SELECTED_EDITION] Equals "Trial" Then
#set compiler variable [SOURCE_FOLDER] = "c:\yada\trial"
#end

By the way, if you use a wildcard and the folder defined in [TPL_TPW] is
empty, the compiler reports something like the follow:

test.sb7(71): warning GEN1022: Wildcard queue empty: e:\test\test\*.*

And of course, the compiler .htm file is your best friend <g>. It lists all
included files with date/time/size/version information.

Friedrich

NewsArchive
01-26-2010, 01:17 AM
Friedrich,

> Unfortunately, this is not possible. In most cases, the values for compiler
> variables are set at compile time.

I'm a bit confused on this one. I use the same compiler variable and
get file sizes on specific filenames but not on wildcards. (image)

If the compiler variable has a value at design time, which mine do<g>,
isn't it possible to use that value to sum the count and file sizes?
If the variable doesn't have a value the size could default to value
shown for Modified, ie: "N/A"... or am I missing something?

> And of course, the compiler .htm file is your best friend <g>. It lists all
> included files with date/time/size/version information.

And it's extremely handy, I use it. The point of the request was for
design time feedback so I might know then that I goofed.

--
Lee White

Enroll Today at http://CWaddons.com

Reports....: http://www.cwaddons.com/products/rpm/
Free Review: http://www.clarionmag.com/cmag/v11/v11n06rpm.html
Faxing.....: http://www.cwaddons.com/products/afe/

NewsArchive
01-26-2010, 01:17 AM
Hi Lee,

If it would be that easy <g>. I see your point, but I bet that we would
receive tons of support emails. Quite a few developers have only a few
wildcard definitions to add 10-20,000 files to the setup.exe. It this
case, it would take some time (minutes!) just to calculate the number and
cumulative file size (recursively). This would completely slow down the
IDE.

Please note that only <10% of all SetupBuilder users are Clarion developers.
Clarion developers can deploy lean applications, so for most Clarioneers
this calculation process would not cause any problem. But for most of the
other developers, it is a problem <g>

BTW, if the "Link To" compiler variable has a value when the file list is
displayed then yes, it reports the file size and date. And if the variable
is not dynamically set at compile time, then the number/size is even
correct. But if there is a wildcard involved, then the "inclusion" and
"exclusion" processing is done at compile time.

I am always open to suggestions, but I fear in this specific case it's
impossible to add it :-(

Friedrich

NewsArchive
01-26-2010, 01:19 AM
Friedrich,

> impossible to add it :-(

For you? NO WAY!

I'll end this discussion with a "thank you" nonetheless... for adding
the following to SB7 which makes the necessity for wild cards somewhat
moot, at least in my case:

Lee White

NewsArchive
01-26-2010, 01:21 AM
Lee,

>> impossible to add it :-(
>
> For you? NO WAY!

As Dirty Harry said, "a man has to know his limitations." <g>

Friedrich