Bob,
That is right. You have to define it without the "new char[32]".
Rather, you should define a factory that would do this for you, or add a
parameter that will take the byte array and assign it to the field.
Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
-
mv*@spam.guard.caspershouse.com
"Bob Costello" <Bo*********@discussions.microsoft.com> wrote in message
news:0F**********************************@microsof t.com...
last post sent prematurely.
This didn't work. Compile error says I can't have instance field
initializers in structs
[StructLayout(LayoutKind.Sequential)]
public struct cdVersionInfo
{
public int Size;
public char[] = new char[32];
}
Thanks in advance.