IVsFileUpgrade2::UpgradeFile Method (String^, String^, Int32, IVsUpgradeLogger^, UInt16, UInt16, UInt16, UInt16, Int32)

 

Upgrade project with a specified file.

Namespace:   Microsoft.VisualStudio.Shell.Interop
Assembly:  Microsoft.VisualStudio.Shell.Interop.9.0 (in Microsoft.VisualStudio.Shell.Interop.9.0.dll)

int UpgradeFile(
	String^ bstrProjectName,
	String^ bstrFileName,
	int bNoBackup,
	IVsUpgradeLogger^ pLogger,
	unsigned short oldToolsVersionMajor,
	unsigned short oldToolsVersionMinor,
	unsigned short newToolsVersionMajor,
	unsigned short newToolsVersionMinor,
	[OutAttribute] int% pUpgradeRequired
)

Parameters

bstrProjectName
Type: System::String^

[in] String containing the name of the project the file belongs to.

bstrFileName
Type: System::String^

[in] String containing the full path and name of the file to upgrade.

bNoBackup
Type: System::Int32

[in] Boolean. If true, no backup file is created.

pLogger
Type: Microsoft.VisualStudio.Shell.Interop::IVsUpgradeLogger^

[in] Pointer to a IVsUpgradeLogger interface to use for logging upgrade actions.

oldToolsVersionMajor
Type: System::UInt16

[in] Major version of old tool.

oldToolsVersionMinor
Type: System::UInt16

[in] Minor version of old tool.

newToolsVersionMajor
Type: System::UInt16

[in] Major version of new tool.

newToolsVersionMinor
Type: System::UInt16

[in] Minor version of new tool.

pUpgradeRequired
Type: System::Int32

[out] Boolean. Set to true if the upgrade succeeded.

Return Value

Type: System::Int32

From vsshell90.idl:

HRESULT UpgradeFile(
    [in]  BSTR               bstrProjectName,
    [in]  BSTR               bstrFileName,
    [in]  BOOL               bNoBackup,
    [in]  IVsUpgradeLogger * pLogger,
    [in]  USHORT             oldToolsVersionMajor,
    [in]  USHORT             oldToolsVersionMinor,
    [in]  USHORT             newToolsVersionMajor,
    [in]  USHORT             newToolsVersionMinor,
    [out] BOOL             * pUpgradeRequired
);
Return to top
Show: