I'm using a vb6 module source code, in a visual basic .net project. The code reads a file in binary mode like this:
, 5022, S
is the file that is being used, 5022 is the place, in the file, to start reading and 'S' is a variant variable. This works just fine in vb6, but in vb .net i've tryed this approach:
Microsoft.VisualBasic.FileGet(1, S, 5022)
But it doesn't work!!!
Instead its given an error message
error code: 5
error message (translated to english): "The calls of delayed entailing for the system file methods in visual basic execution time, are not allowed"
I've also tryed to use the BinaryReader with Filestreams but they have one problem which is that the arguments are different. BinaryReader.Read() needs the 'count characters' from the place where he will start reading. Something that 'Get' doesn't need.
what other choices do i have or what can i do to continue to use 'Get' or a similiar function in Visual Basic .net
My thanks in advanced