CString::ReleaseBuffer

This method releases a buffer allocated by GetBuffer. If you know that the string in the buffer is null-terminated, you can omit the nNewLength parameter. If your string is not null-terminated, then use nNewLength to specify its length. The address returned by GetBuffer is invalid after the call to ReleaseBuffer or any other CString operation.

At a Glance

Header file: Afx.h
Platforms: H/PC 2.0, Palm-size PC, H/PC Pro
Windows CE versions: 1.0 and later
Complete documentation: Visual C++ documentation

Syntax

void ReleaseBuffer( int nNewLength = 1 );

See Also

CString::GetBuffer