If you must try to do a "line for line" conversion of the code (I DONT'T recommend it!), you're looking for the
BinaryReader[
^] and
BinaryWriter[
^] classes. It lets you do all kinds of reads and writes for various types (byte, int16, int32, int64, signed byte, single, ...)
They don't provide any functionality to Seek around the file though. That's easy enough to do by opening the file with a FileStream, which will allow you to seek around. This FileStream can then be passed to a BinaryReader/Writer which will allow you to read/write exactly what you want.
Using myFile As FileStream = File.Open(filename, FileMode.Open)
Using fileContent As New BinaryReader(myFile)
myFile.Seek(position)
Dim someValue As Integer = fileContent.ReadInt32();
End Using
End Using