Share via


CString::ReverseFind

This method searches this CString object for the last match of a substring. The method is similar to the _tcsrchr run-time function.

  int ReverseFind(
TCHAR 
  ch
  )
const;
   

Parameters

  • ch
    Specifies the character to search for.

Return Value

Returns the index of the last character in this CString object that matches the requested character; ・ if the character is not found.

Example

  // Example for CString::ReverseFind
CString s("abcabc");
ASSERT(s.ReverseFind('b') == 4);

Requirements

  Windows CE versions: 1.0 and later
  Header file: Declared in Afx.h
  Platform: H/PC Pro, Palm-size PC, Pocket PC

See Also

CString::Find, CString::FindOneOf