Check and convert the substring before the separator token to an integer and return the remaining string
LPSTR is_str_numeric_integer_with_args( LPSTR lpsz, int * lpnVal, char cSeparator = ':' )
pointer to the buffer after the separator character with leading and trailing spaces removed, or NULL if leading part of string is not an integer
EX1
void is_str_numeric_integer_with_args_ex1() { //convert the substring before the separator, return remain str //change the '/' to other separator to see differrent result int ii = 0; string str = is_str_numeric_integer_with_args("123/ 456 ", &ii , '/'); if( ("456" == str) && (123 == ii) ) printf("remain str is \"%s\" converted integer is %d\n", str , ii); else printf("convert failed\n"); }
is_str_numeric_integer, is_str_numeric
origin.h