NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

Marshal.OffsetOf

Returns the byte offset for a field within a class used by Marshal.

[Visual Basic]
Public Shared Function OffsetOf( _
   ByVal t As Type, _
   ByVal fieldName As String _
) As Integer
[C#]
public static int OffsetOf(
   Type t,
   string fieldName
);
[C++]
public: static int OffsetOf(
   Type* t,
   String* fieldName
);
[JScript]
public static function OffsetOf(
   t : Type,
   fieldName : String
) : int;

Parameters

t
[To be supplied.]
fieldName
Field within class.

Return Value

Offset in bytes, for fieldname within the PInvoke-declared class c.

See Also

Marshal Class | Marshal Members | System.Runtime.InteropServices Namespace