-
Binary Streaming
I'm quite new to C#, and i was wondering how would i make a program that can read and write to a certain offset of a file, see im trying to make a tag creator/editor for the game Halo.
so i guess what im asking... is how would i make it so say... offset 40 of the file being opened (lets says its 3f 80), how would i get '1' to display in say textBox1... lol sorry if this is confusing :P
edit: i did some research and i found what i need to do, its called Binary Streaming, anyone know how to do this :P the tutorial i found isnt to noob friendly -_-
-
Re: Binary Streaming
look up the BinaryReader, BinaryWriter, and FileStream class in the System.IO namespace...
the StreamReader and StreamWriter classes could be helpful too:D
-
Re: Binary Streaming
do you think you could post an example source, im not good with tutorials or anything, im more of a visual learner >_>
-
Re: Binary Streaming
The help topics have example code. You will have to read something whether it be help files, web pages or code examples posted here. None of them will be exactly what you want so you have to do some work yourself.
-
Re: Binary Streaming
You can do something like this to move to position 40.
PS: Just remember to open the file between line one and two here...
Code:
BinaryReader br = new BinaryReader();
br.BaseStream.Position = 40;
- ØØ -