Returns the size of a fixed or a numeric variable in bits
% = BitSizeOf(variable)
variable: avar
With the function BitSizeOf you get the size of a numeric variable, a fixed string, type elements, array’s, etc..
OpenW 1
Type atest
- Byte a
- Int b
- Double c
- Byte d
EndType
Dim a As atest
a.a = 1 : a.b = 2 : a.c = 3 : a.d = 4
Print " Size of the element in bit"
Print "BitSizeOf of a: ", BitSizeOf(a.a)
Print "BitSizeOf of b: ", BitSizeOf(a.b)
Print "BitSizeOf of c: ", BitSizeOf(a.c)
Print "BitSizeOf of d: ", BitSizeOf(a.d)
Print " Size of the element's in byte"
Print "SizeOf of a: ", SizeOf(a.a)
Print "SizeOf of b: ", SizeOf(a.b)
Print "SizeOf of c: ", SizeOf(a.c)
Print "SizeOf of d: ", SizeOf(a.d)
Do
Sleep
Until Me Is Nothing
{Created by Sjouke Hamstra; Last updated: 20/10/2014 by James Gaite}