title: Converting byte array to String Java
body: <p>I wish to convert a byte array to String but as I do so, my String has 00 before every digit got from the array.</p>
  
  <p>I should have got the following result: 49443a3c3532333437342e313533373936313835323237382e303e</p>
  
  <p>But I have the following:</p>
  
  <p><a href="https://i.stack.imgur.com/yPEQ7.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/yPEQ7.png" alt="enter image description here"></a></p>
  
  <p>Please help me, how can I get the nulls away?</p>
  
  <p>I have tried the following ways to convert:</p>
  
  <p>xxxxId is the byteArray</p>
  
  <p>String xxxIdString = new String(Hex.encodeHex(xxxxId));</p>
  
  <p>Thank you!</p>