Pergunta

Qualquer dicas sobre análise / converter / operando em valores hexadecimais no c #?

Em particular eu quero lançar um int decimal para hexadecimal e de saída, em seguida, como uma string ...

Foi útil?

Solução

Int32 decValue = 42;
string hexValue = decValue.ToString("X");

Int32 decValue2 = Int32.Parse(hexValue, System.Globalization.NumberStyles.HexNumber);

Veja este post:

Como converter números entre hexadecimal e decimal em C #?

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top