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!

ModuleBuilder.SetUserEntryPoint

Sets the user entry point.

[Visual Basic]
Public Sub SetUserEntryPoint( _
   ByVal entryPoint As MethodInfo _
)
[C#]
public void SetUserEntryPoint(
   MethodInfo entryPoint
);
[C++]
public: void SetUserEntryPoint(
   MethodInfo* entryPoint
);
[JScript]
public function SetUserEntryPoint(
   entryPoint : MethodInfo
);

Parameters

entryPoint
The user entry point.

Exceptions

Exception Type Condition
ArgumentNullException if entryPoint is a null reference (in Visual Basic Nothing)
InvalidOperationException if this method is called on a dynamic module that is not a debug module or if entryPoint is not contained in this dynamic module

Remarks

The compiler may generate a startup stub before calling user main. The startup stub will be the entry point. While the user "main" will be the user entry point so that debugger will not step into the compiler entry point.

Requirements

NGWS Runtime Security:

ReflectionPermission SecurityAction.Demand, ReflectionEmit

See Also

ModuleBuilder Class | ModuleBuilder Members | System.Reflection.Emit Namespace