%MEMCCPY

%MEMCCPY


%MALLOC Index Level %MEMCPY
Syntax variable = (char*)%MEMCCPY( s1, s2, (char)character, length )
Category BASIC
Type C Function
Description copies characters from memory area specified by "s2" into "s1", stopping after the first occurrence of character designated by "character" has been copied, or after the number of characters specified by "length" have been copied, whichever comes first.

"s1" and "s2" are either FlashBASIC strings or pointers to a character.

"variable" is a pointer to the character after the copy of "character" in "s1" or a NULL pointer if "c" was is found in the first "length" characters of "s2". If "s1" is a Pick string, the value returned by this function, except NULL, has no meaning.
Options
See Also c function CFUNCTION %MEMXCPY
Example
Warnings If the source string contains a segment mark (x'ff'), the string is truncated.
Compatibility D3/Unix
%MALLOC Index Level %MEMCPY