Use a pointer to skip the prefix alphabetic characters, then use
strtol[
^] to convert the number to a long value. The
endptr
variable will then point to the first non-numeric character, allowing you to parse further. Something like:
char* strData = "*H1999999#";
char* strNum = strData + 2;
char* strEnd = NULL;
long lValue = strtol(strNum, &strEnd, 10);