Converting a byte array to a ushort array

F

fishspm

hello everyone

in my source I receive a byte array (for eg: 0xED, 0xFF, 0x01, 0x3D).
is there an easy way to convert this byte array to a ushort/uint16
array (0xffed, 0x3d01)?

thank you very much for advice

Regards,

H
 
M

Mattias Sjögren

in my source I receive a byte array (for eg: 0xED, 0xFF, 0x01, 0x3D).
is there an easy way to convert this byte array to a ushort/uint16
array (0xffed, 0x3d01)?

System.Buffer.BlockCopy


Mattias
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top