using (Stream stream = new FileStream(path, FileMode.OpenOrCreate)) { byte[] fv = Encoding.ASCII.GetBytes(firstValue); byte[] position = Encoding.ASCII.GetBytes(pos); byte[] AscFind = Encoding.ASCII.GetBytes(AscFinding); stream.Position = 0; stream.Write(fv, 0, firstValue.Length); stream.Position = Convert.ToInt32(pos); int ps = Convert.ToInt32(pos); stream.Write(AscFind, ps, AscFinding.Length); }
am getting error
"Offset and length were out of bounds for the array or count is greater than the number of elements from index to the end of the source collection."
1.4m articles
1.4m replys
5 comments
57.0k users