psz, len)
char FAR* psz
unsigned int len

Allocates a new string of len bytes, copies len bytes from the passed string into it, and then appends a null character. Valid for 32-bit systems only.



A zero-terminated string to copy, or NULL to keep the string uninitialized.


Number of bytes to copy from psz. A null character is placed afterwards, making a total of len+1 bytes allocated.

Return Value

Points to a copy of the string or NULL, if insufficient memory exists.


If psz is NULL, a string of the requested length is allocated, but not initialized. The string psz can contain embedded null characters and need not end with a null. The returned string should later be freed with SysFreeString.

Software for developers
Delphi Components
.Net Components
Software for Android Developers
More information resources
Unix Manual Pages
Delphi Examples
Databases for Amazon shops developers
Amazon Categories Database
Browse Nodes Database