[DllImport("msvcrt.dll", SetLastError=true)]
static extern IntPtr fopen(String filename, String mode);
Declare Function fopen Lib "msvcrt.dll" (String filename, String mode) As IntPtr
None.
None.
I could not get the above signature to work, so I altered them slightly and this seems to work better:
[DllImport("msvcrt.dll", CallingConvention = CallingConvention.Cdecl, CharSet = CharSet.Ansi)]
static extern IntPtr fopen(String filename, String mode);
[DllImport("msvcrt.dll", CallingConvention = CallingConvention.Cdecl, CharSet = CharSet.Ansi)]
static extern Int32 fclose(IntPtr file);
Please add some!
System.IO.FileStream