• Advertisement

Archived

This topic is now archived and is closed to further replies.

byte array to an integer array

This topic is 5072 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

How is this done in c#, i''ve tried to do so by casting explicitly but it doesn''t except it??

Share this post


Link to post
Share on other sites
Advertisement

byte[] bytes = ...;
int [] ints = new int[bytes.length];

for(int i=0; i < ints.length; ++i)
ints[ i ] = (int)bytes[ i ];


- Pete

[edited by - Pete_ on April 3, 2004 5:01:08 PM]

Share this post


Link to post
Share on other sites

  • Advertisement