帮助里不是有吗?
Converts a string of hexadecimal digits to the corresponding binary value.UnitClassesCategorytype conversion routinesfunction HexToBin(Text, Buffer: PChar; BufSize: Integer): IntegerDescriptionCall HexToBin to convert the hexadecimal string Text to the binary value it represents.Text is a string representation of a hexadecimal value.Buffer returns the resulting value in binary.BufSize is the size of Buffer. Text needs to point to at least 2*BufSize hexadecimal characters, because each two hexadecimal characters represent one byte.HexToBin returns the number of characters in Buffer that have not been used because Text did not contain valid hexadecimal characters ('0'..'f').Note: The hexadecimal number must use lower-case characters; HexToBind does not recognize upper-case characters.