Binary String to bytes and/or HEX-string?

  • Thread starter Thread starter Kenneth Priisholm
  • Start date Start date
K

Kenneth Priisholm

Hi there.

I'm trying to find a built-in function in the framework for converting
binary formatted strings into either bytes or HEX-values; something that
works in a similar fashion as BitConverter.ToString(byte[]), which converts
a byte-array into HEX, or Convert.ToString(byte, 2), which converts a byte
into a binary string - just the other way arround.

Am I just looking in the wrong direction, or is there really no built-in
function/formatter for this task? Since I've browsed msdn and all sorts of
sites, but so far haven't had any luck, it seems, that the task must be so
trivial that it's hardly documented - or what?

Thank you in advance!

Best regards,
Ken.
 
Hi William.

Thank you, that just made my day! :-)

- Just as trivial, simple and cool as pressumed...

As mentioned in the post, I think the documentation generally lacks a
bit on the formatting side; do you know of any good books, articles or
other sources to clear up this matter for the
not-so-experienced-regarding-formatting-in-the-.Net-framework?

Cheers,
Ken.
 
Back
Top