LabWindows/CVI

Content Type
Programming Language
Current manual
Table of Contents

_mbscspn

_mbscspn

size_t _mbscspn (const char stringToSearch[], const char characterSet[]);

Purpose

Locates the position of the first character in a string that is from a specified set of characters. The return value corresponds to the length in bytes of the initial segment of the string that contains no character from the specified set.

Refer to the Programming for Multibyte Character Sets in LabWindows/CVI topic for information about working with multibyte character sets.

Parameters

Input
Name Type Description
stringToSearch const char [] Contains a pointer to the string that is searched to locate any of the characters specified in characterSet.
characterSet const char [] Contains a pointer to the character set containing the characters that are searched for in the specified string.

Return Value

Name Type Description
matchedCharIndex size_t Contains the index value of the string corresponding to the first matched character from the character set. If no matching characters are found, the function returns the index of the terminating ASCII NUL byte. This value also corresponds to the length in bytes of the initial segment of the string containing no character from the character set.

Additional Information

Library: ANSI C Library

Include file: ansi_c.h

LabWindows/CVI compatibility: LabWindows/CVI 6.0 and later

Was this information helpful?

Previous

_mbspbrk

Previous

_mbspbrk