5 Replies Latest reply: Nov 28, 2006 1:45 PM by jschellSomeoneStoleMyAlias RSS

    How do a convert a number in a 4 byte array?

      I am trying to convert a C++ style floating point number held in 4 bytes to a Java float.

      I have read the 4 bytes making up the number into a byte array. I then build a StringBuffer of these bytes.

      I do not know how to convert this Stringbuffer, or the original 4 bytes, into a Java float.

      How do I acheive this conversion?

      FYI the data is from a UDP source.

      Any help would be greatly appreciated.