Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Gets the minimum versions of the target framework required for the given assembly to run.
Namespace: Microsoft.VisualStudio.Shell.Interop
Assembly: Microsoft.VisualStudio.Shell.Interop.9.0 (in Microsoft.VisualStudio.Shell.Interop.9.0.dll)
Syntax
'Declaration
Function GetRequiredTargetFrameworkVersion ( _
szAssemblyFile As String, _
<OutAttribute> ByRef pTargetFrameworkVersion As UInteger _
) As Integer
int GetRequiredTargetFrameworkVersion(
string szAssemblyFile,
out uint pTargetFrameworkVersion
)
int GetRequiredTargetFrameworkVersion(
[InAttribute] String^ szAssemblyFile,
[OutAttribute] unsigned int% pTargetFrameworkVersion
)
abstract GetRequiredTargetFrameworkVersion :
szAssemblyFile:string *
pTargetFrameworkVersion:uint32 byref -> int
function GetRequiredTargetFrameworkVersion(
szAssemblyFile : String,
pTargetFrameworkVersion : uint
) : int
Parameters
- szAssemblyFile
Type: System.String
[in] Path to the assembly to check.
- pTargetFrameworkVersion
Type: System.UInt32%
[out] A WellKnownTargetFrameworkVersions value specifying the required framework version.
Return Value
Type: System.Int32
If the method succeeds, it returns S_OK. If it fails, it returns an error code.
Remarks
This method will return a framework version only if it can be determined with a given assembly, otherwise it will return TargetFrameworkVersion_Unknown.
COM Signature
From compsvcspkg90.idl:
HRESULT GetRequiredTargetFrameworkVersion(
[in] LPCOLESTR szAssemblyFile,
[out] TARGETFRAMEWORKVERSION *pTargetFrameworkVersion
);
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.