Partager via


SysAllocString (Windows CE 5.0)

Send Feedback

This function allocates a new string and copies the passed string into it. This function returns null if there is insufficient memory or if a null pointer is passed in.

BSTRSysAllocString(OLECHARFAR* sz ); 

Parameters

  • sz
    [in] Null-terminated string to copy. The string must be a Unicode string in 32-bit applications, and an ANSI string in 16-bit applications.

Return Values

Returns the allocated string to indicate success, or NULL to indicate that insufficient memory exists or that the sz parameter was NULL.

Remarks

Windows CE supports only Unicode strings.

Passing invalid (and under some circumstances NULL) pointers to this function causes an unexpected termination of the application.

You can free strings created with SysAllocString using SysFreeString.

Requirements

OS Versions: Windows CE 2.0 and later.
Header: Oleauto.h.
Link Library: Oleaut32.lib.

See Also

Automation Functions | SysFreeString

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.