xtoi (Hex to Integer) C function
Tuesday, June 20, 2006 6:06 PM byYou mean "int to hex"?
Use sprintf:
char* output;
unsigned int value = 43981; sprintf(output, "%X", value);
Edit:
From the comment below the page, you can see the C way of decoding hex from string using function:unsigned int hex = 0;const char* hexstr = "ABCD";sscanf(hexstr, "%X", &hex);printf("%s = %d\n", hexstr, hex);