Z
Zoury
Hi folks! :O)
I found this posted by Matthias on february 2001 :
[MarshalAs(UnmanagedType.ByValTStr, SizeConst=32)]
string blabla;
or this posted by Matthias on december 2003 :
[MarshalAs(UnmanagedType.ByValArray, SizeConst=123)]
public char[] chars;
in both scenario the OP needed to work with APIs. What I want to do is to
dump/read data from a customly formated file.
in VB 6, we could declare something like the following :
'***
Type MyType
Code As String * 3
Name As String * 25
End Type
'***
and then write/read the given Type directly into a file.
Would this be possible in C# using one of the above way (and a BinaryWriter
i guess) ?
I found this posted by Matthias on february 2001 :
[MarshalAs(UnmanagedType.ByValTStr, SizeConst=32)]
string blabla;
or this posted by Matthias on december 2003 :
[MarshalAs(UnmanagedType.ByValArray, SizeConst=123)]
public char[] chars;
in both scenario the OP needed to work with APIs. What I want to do is to
dump/read data from a customly formated file.
in VB 6, we could declare something like the following :
'***
Type MyType
Code As String * 3
Name As String * 25
End Type
'***
and then write/read the given Type directly into a file.
Would this be possible in C# using one of the above way (and a BinaryWriter
i guess) ?