Garry's Mod Wiki

string.NiceSize

string string.NiceSize( number bytes )

Description

Converts a digital filesize to human-readable text.

Arguments

1 number bytes
The filesize in bytes.

Returns

1 string
The human-readable filesize, in Bytes/KB/MB/GB (whichever is appropriate).

Example

Example output of this function.

Output: 63 KB

Page Links


Special Pages


Wikis

?

Render Time: 21ms

DB GetPage 4
Generate Html 2
SaveChanges (1) 8
Render Body 0
Render Sidebar 5