Page 1 of 1
How to make a division?
Posted: Tue Feb 06, 2007 12:11 pm
by Alejandro
I made a task to determinate the total HDD usage, but it gives me bytes, I want to convert it to gb's... where may I make a division of a value??? in this case {TOTAL_SIZE}/1073741824I searched the forum and the online help without success...
How to make a division?
Posted: Tue Feb 06, 2007 10:39 pm
by Oleg
There is Evaluate action for this purpose. This is in additional BASIC plugin. Just download here and install it.
BASIC plugin contain two actions:
Evaluate - for evaluating any mathematic expressions
BASIC script - for writing small subprograms on BASIC language
How to make a division?
Posted: Wed Feb 07, 2007 9:37 am
by Alejandro
The more I use this thing the more I love it :)I'll try it. Thank you...
How to make a division?
Posted: Wed Feb 07, 2007 3:55 pm
by Alejandro
It worked... but I get the "error in expression" messsage... I tried several ways until I realized that i'ts because the size of the numbers... is the disk space in bytes (about 40,000,000,000) if I reduce the number to 400,000,000 (nine digits) it works...I can show numbers bigger than 9 digits, but I can't make operations with them (in this case a division) is this normal??? Is there a way to fix it???Thank you...
How to make a division?
Posted: Wed Feb 07, 2007 10:42 pm
by Oleg
Try to use the expression {TOTAL_SIZE}#/1073741824
Symbol '#' says to BASIC that {TOTAL_SIZE} is a double value (a floating point )not an integer. DOUBLE have more large range of values. By default Basic think that {TOTAL_SIZE} is an integer value. This is small trick to avoid an error.
Also you may write so: {TOTAL_SIZE}.0/1073741824
How to make a division?
Posted: Fri Feb 09, 2007 7:01 pm
by Alejandro
duh :)Now working fine.Thank you...!