Documentation Index
Fetch the complete documentation index at: https://notevil.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
Open topic with navigation
CAPL Functions » General » Function Overview » strlen
strlen
Valid for: CANoe DE • CANoe:lite DE • CANoe4SW DE • CANoe4SW:lite DE
Function Syntax
Description
The functional result is the length of the string s in bytes.
Note: A character may need several bytes depending on the string encoding, e.g. Japanese characters in Windows ANSI (932) encoding or any special characters in UTF-8 encoding. In that case, you may want to use mbstrlen instead.
Parameters
string
Return Values
Length of the string in bytes.
Example
long length;
char buffer[100] = "CANalyzer";
length = strlen(buffer);
Result:
strncat • strncmp • strncpy