This function retrieves the length of a string.
The returned value can be different from _fstrlen(bstr) if the following occurred:
If BSTR was allocated with SysAllocStringLen, SysReAllocStringLen, or SysAllocStringByteLen
If the passed-in characters included a null character in the first cch characters
For a BSTR allocated with SysAllocStringLen, SysAllocStringLen, or SysAllocStringByteLen, the SysStringLen function retrieves the number of characters specified in the cch parameter at allocation time.
Windows Embedded CE and Windows Mobile only support Unicode strings.
Passing invalid (and under some circumstances NULL) pointers to this function causes an unexpected termination of the application.