SetEntryPoint Method (MethodInfo)
Collapse the table of content
Expand the table of content

AssemblyBuilder.SetEntryPoint Method (MethodInfo)

 

Sets the entry point for this dynamic assembly, assuming that a console application is being built.

Namespace:   System.Reflection.Emit
Assembly:  mscorlib (in mscorlib.dll)

public void SetEntryPoint(
	MethodInfo entryMethod
)

Parameters

entryMethod
Type: System.Reflection.MethodInfo

A reference to the method that represents the entry point for this dynamic assembly.

Exception Condition
ArgumentNullException

entryMethod is null.

InvalidOperationException

entryMethod is not contained within this assembly.

SecurityException

The caller does not have the required permission.

ReflectionPermission

when invoked late-bound through mechanisms such as Type.InvokeMember. Associated enumeration: ReflectionPermissionFlag.MemberAccess.

.NET Framework
Available since 1.1
Silverlight
Available since 2.0
Return to top
Show:
© 2016 Microsoft