A
Asc3nti0n
Hi Everyone,
I'm trying to format a few series of bytes as something that is a
little more legible, and truncating the number of decimal points.
While the link 'Local Tips on Custom Formatting eg.'
(http://www.exceltip.com/st/Formatting_numbers_according_to_criteria_in_Microsoft_Excel/71.html)
has been a great aid in getting the general drift of how to write the
custom format strings, it doesn't aid debugging something that errors.
I have the following line:
I have been able to add the byte suffix to the amount, and divide the
source number of bytes with a nested IF statement:
outside the printable space.
It's logically correct, but this method doesn't allow for the reduction
of the decimal points. Because CONC output appears as a text field to
excel.
So if the Custom Format string could be made to reflect it, and the
0.000 function of it work correctly....
Any comments appreciated.
Thanks
Tim Leech
IT User Committee Coordinator, Accom. Providers, La Trobe
University, Melbourne, AUSTRALIA.
I'm trying to format a few series of bytes as something that is a
little more legible, and truncating the number of decimal points.
While the link 'Local Tips on Custom Formatting eg.'
(http://www.exceltip.com/st/Formatting_numbers_according_to_criteria_in_Microsoft_Excel/71.html)
has been a great aid in getting the general drift of how to write the
custom format strings, it doesn't aid debugging something that errors.
I have the following line:
[<1099511627776]((#,##0.000)/1099511627776)"
TB";[<1073741824]((#,##0.000)/1073741824)"
GB";[<1048576]((#,##0.000)/1048576)" MB";[<1024]((#,##0.000)/1024)"
kB";(#,##0)" Bytes"
I have been able to add the byte suffix to the amount, and divide the
source number of bytes with a nested IF statement:
Where P is the column I have copied the raw byte amount across to,=CONCATENATE((IF($P2>1024,(IF($P2>(1024*1024),(IF($P2>(1024*1024*1024),$P2/(1024*1024*1024),$P2/(1024*1024))),$P2/(1024))),$P2)),"
",(IF($P2>1024,(IF($P2>(1024*1024),(IF($P2>(1024*1024*1024),"GB","MB")),"kB")),"Bytes")))
outside the printable space.
It's logically correct, but this method doesn't allow for the reduction
of the decimal points. Because CONC output appears as a text field to
excel.
So if the Custom Format string could be made to reflect it, and the
0.000 function of it work correctly....
Any comments appreciated.
Thanks
Tim Leech
IT User Committee Coordinator, Accom. Providers, La Trobe
University, Melbourne, AUSTRALIA.