| ExtensionsReflectionCreateInstance Method (ConstructorInfo, Object) |
Creates an instance of the specified type using the constructor
Namespace:
Cauldron
Assembly:
Cauldron.Activator (in Cauldron.Activator.dll) Version: 3.2.0.2
Syntax Parameters
- ctor
- Type: System.ReflectionConstructorInfo
The constructor use to construct the instance - args
- Type: SystemObject
An array of arguments that match in number, order, and type the parameters of the
constructor to invoke. If args is an empty array or null, the constructor that takes no
parameters (the default constructor) is invoked.
Return Value
Type:
ObjectA reference to the newly created object.
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type
ConstructorInfo. When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic) or
Extension Methods (C# Programming Guide).
Exceptions See Also