Hi Everyone -
I have two questions about MarshalAs
1) I need to setup the correct MarshalAs for this setup...
[StructLayout(La youtKind.Sequen tial)]
public struct DateTimeStruct
{
public int year;
public int month;
public int day;
public int hour;
public int minute;
public int second;
}
What would the correct MarshalAs statement be?
This is what i'm trying...
[MarshalAs( UnmanagedType.S truct)]
DateTimeStruct startTime;
2) Given this struct element -
int samplingInterva l[5]
What would the correct MarshalAs statement be?
This is what i'm thinking...
[MarshalAs( UnmanagedType.B yValArray, SizeConst=5)]
int samplingInterva l;
Would someone please correct my direction on these two questions??
thanks
tony
I have two questions about MarshalAs
1) I need to setup the correct MarshalAs for this setup...
[StructLayout(La youtKind.Sequen tial)]
public struct DateTimeStruct
{
public int year;
public int month;
public int day;
public int hour;
public int minute;
public int second;
}
What would the correct MarshalAs statement be?
This is what i'm trying...
[MarshalAs( UnmanagedType.S truct)]
DateTimeStruct startTime;
2) Given this struct element -
int samplingInterva l[5]
What would the correct MarshalAs statement be?
This is what i'm thinking...
[MarshalAs( UnmanagedType.B yValArray, SizeConst=5)]
int samplingInterva l;
Would someone please correct my direction on these two questions??
thanks
tony