The amount of required/remaining disk space is always displayed with American/English settings (comma seperated). How to format this?
Furthermore I like to display this always in MB? How to do this?
Display of required/remaining disk space?
Display of required/remaining disk space?
Evaluating InstallAware ...
Re: Display of required/remaining disk space?
To express the size in MB, you need to add up all of the results for Get Component Space for each component/web media block/feature. Note that there is currently a bug and leaving Get Component Space blank does not get total required space, but OFFLINE CONTENT, so if you have any offline content, you will need to add that as well.
That result will be expressed in bytes. Knowing there are 1048576 Bytes in a MB, you will have to divide your result by 1048576. Note that this value will be rounded
That result won't be formatted.
Then, you need to determine the size of the result and insert commas appropriately.
Here's sample code:
That result will be expressed in bytes. Knowing there are 1048576 Bytes in a MB, you will have to divide your result by 1048576. Note that this value will be rounded
That result won't be formatted.
Then, you need to determine the size of the result and insert commas appropriately.
Here's sample code:
Code: Select all
~InstallAware Clipboard Data~
~MessageBox~
~{C65FC3D5-991A-48AF-BA1E-86AA80277604}~
~fileSize (edited)~
~E = $fileSize$~
~0~
~1~
~~
~End~
~{65A90C48-EE9F-4B88-AE72-0EE6585CDDF7}~
~End~
~{7A2AAFB9-A87A-4EDE-B34E-FC52E490D6E1}~
~Set Variable~
~{7293158F-8B5D-4A73-BB42-B63318676A55}~
~fileSize$MYAH$MYAH$FALSE~
~$first$,$second$~
~Parse String~
~{FBC5C374-5347-4CB8-8E48-A1E49366882B}~
~$fileSize$~
~1~
~first~
~second~
~2~
~FALSE~
~FALSE~
~Comment~
~{9E7CDF7C-26CA-4895-9A7E-9060B62C34F8}~
~between 1,000 9,999~
~Else~
~{E9D527CB-A582-4E25-986A-7CB054BAE0E8}~
~If~
~{7ED45C13-6953-46B2-BE68-C3AF9B125CBB}~
~fileSize~
~2~
~9999~
~FALSE~
~If~
~{99117E87-0A9E-4A36-823F-A8CBE03EF36E}~
~fileSize~
~2~
~999~
~FALSE~
~Set Variable~
~{9E964162-91C5-445A-9CB7-CBE168F4F574}~
~second$MYAH$MYAH$FALSE~
~~
~Set Variable~
~{31AC5326-0A04-4205-A3BF-EE3802757C25}~
~first$MYAH$MYAH$FALSE~
~~
~Comment~
~{99B38B45-1D8F-4F88-AA61-00ABA8AABAF0}~
~~
~MessageBox~
~{CC2C8C41-31BF-4D13-A90F-399F7E4EC85B}~
~filesize~
~F = $fileSize$~
~0~
~1~
~~
~Comment~
~{0A8782A9-1B67-4ACA-9D4E-56D47351314D}~
~~
~Mathematics~
~{5D67F2F1-0EC2-4108-A49E-CE48B78D823E}~
~$fileSize$~
~1048576~
~3~
~fileSize~
~Comment~
~{F9517A4C-F9AB-44B4-80CE-FCF49A30F206}~
~~
~Set Variable~
~{79C4904A-3A31-4A4B-BA96-B8348A9E4097}~
~fileSize$MYAH$MYAH$FALSE~
~9589634592~
Andy Mills
InstallAware
Other Help:
White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Product Guides - http://www.installaware.com/publication ... guides.htm
InstallAware Help - Press F1 in the InstallAware IDE.
InstallAware
Other Help:
White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Product Guides - http://www.installaware.com/publication ... guides.htm
InstallAware Help - Press F1 in the InstallAware IDE.
Re: Display of required/remaining disk space?
First of all thank you for the reply, but all that i know already about. What I am searching for is how to display the formated values (e.g. in MegaByte an with dot seperated) in the dialog fields named TotalRequiredSpace and RemainingSpace? Here an example:
OLD (values with comma and KB/MB):
NEW (values with dot an both in MB):
This should even work properly (in realtime) when I change the path by using the Browser-Control ... then the new values should be re-calculated and displayed as my "formated values".
Please help on that ...
OLD (values with comma and KB/MB):
NEW (values with dot an both in MB):
This should even work properly (in realtime) when I change the path by using the Browser-Control ... then the new values should be re-calculated and displayed as my "formated values".
Please help on that ...
Evaluating InstallAware ...
Re: Display of required/remaining disk space?
Andy Mills
InstallAware
Other Help:
White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Product Guides - http://www.installaware.com/publication ... guides.htm
InstallAware Help - Press F1 in the InstallAware IDE.
InstallAware
Other Help:
White Papers (HowTos) - http://www.installaware.com/publication ... papers.htm
Product Guides - http://www.installaware.com/publication ... guides.htm
InstallAware Help - Press F1 in the InstallAware IDE.
Re: Display of required/remaining disk space?
mills wrote:I see. This is already a feature request:
It's a bug, still unresolved since 15 years.
Here is an article about the Decimal separator. All countries that use a comma as decimal seperator use a dot as thousand separator.
We wouldn't be able to sell a single license of our software to American customers and customers in other mostly-english-speeking countries if we disrespected the user format settings of the target system. The image shows how large numbers have to be formatted on a German system.
The fix is done by adding two or three lines of code, including thread-safety.
Best regards
pfennig
pfennig
Who is online
Users browsing this forum: Google [Bot] and 27 guests