Share via


GetMethod Method

[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]

Retrieves a MethodInfo object that corresponds to a specified method under specified search constraints.

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

Syntax

'Declaration
Function GetMethod ( _
    name As String, _
    bindingAttr As BindingFlags _
) As MethodInfo
MethodInfo GetMethod(
    string name,
    BindingFlags bindingAttr
)
MethodInfo^ GetMethod(
    String^ name, 
    BindingFlags bindingAttr
)
abstract GetMethod : 
        name:string * 
        bindingAttr:BindingFlags -> MethodInfo 
function GetMethod(
    name : String, 
    bindingAttr : BindingFlags
) : MethodInfo

Parameters

Return Value

Type: System.Reflection. . :: . .MethodInfo
A MethodInfo object containing the method information, with the match being based on the method name and search constraints specified in bindingAttr.

.NET Framework Security

See Also

Reference

IReflect Interface

System.Reflection Namespace