StrFormatKBSizeA function

Converts a numeric value into a string that represents the number expressed as a size value in kilobytes.

Syntax

PSTR StrFormatKBSizeA(
  LONGLONG qdw,
  PSTR     pszBuf,
  UINT     cchBuf
);

Parameters

qdw

Type: LONGLONG

The numeric value to be converted.

pszBuf

Type: PTSTR

A pointer to a buffer that, when this function returns successfully, receives the converted number.

cchBuf

Type: UINT

The size of pszBuf, in characters.

Return Value

Type: PTSTR

Returns a pointer to the converted string, or NULL if the conversion fails.

Remarks

In Windows 10, size is reported in base 10 rather than base 2. For example, 1 KB is 1000 bytes rather than 1024.

Requirements

   
Minimum supported client Windows 2000 Professional, Windows XP [desktop apps only]
Minimum supported server Windows 2000 Server [desktop apps only]
Target Platform Windows
Header shlwapi.h
Library Shlwapi.lib
DLL Shlwapi.dll (version 5.0 or later)

See Also

StrFormatByteSizeA

StrFormatByteSizeW