Platform SDK: Windows Management Instrumentation |
The Right method extracts the last (that is, rightmost) nCount characters from a CHString string and returns a copy of the extracted substring. If nCount exceeds the string length, then the entire string is extracted.
CHString Right( int nCount ) const throw( CHeap_Exception );
Returns a CHString object that contains a copy of the specified range of characters. Note that the returned CHString object can be empty.
The following example demonstrates the use of CHString::Right:
CHString s( L"abcdef" ); assert( s.Right(2) == L"ef" );
Windows NT/2000: Requires Windows NT 4.0 SP4 or later.
Windows 95/98: Requires Windows 95 OSR2 or later.
Header: Declared in Chstring.h.
Library: Use Framedyn.lib.