Get bytes after index in byte[]

arrays, c#

Solution

How about

byte[] bytes = Encoding.UTF8.GetBytes("samebytesDataNeededIsHere");
byte[] bytesToUse = bytes.Skip(countOfBytesToSkip).ToArray();

Problem

Possible Duplicate: C# arrays , Getting a sub-array from an existing array Basically I have a `byte[]` that's going to be different every time, but it's going to be the same length. Then, after that, I have more bytes with the data that I need. If that doesn't make sense, this is basically what I mean. ``` "samebytesDataNeededIsHere" ``` So I need to get the data after "samebytes", and I'm not sure how to do it. I've searched and there's really nothing on this, besides byte patterns and that's not really what I need.

Original source

Related problems