IVsProjectUpgradeViaFactory::UpgradeProject Method

Upgrades a project.

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

int UpgradeProject(
	[InAttribute] String^ bstrFileName, 
	[InAttribute] unsigned int fUpgradeFlag, 
	[InAttribute] String^ bstrCopyLocation, 
	[OutAttribute] String^% pbstrUpgradedFullyQualifiedFileName, 
	[InAttribute] IVsUpgradeLogger^ pLogger, 
	[OutAttribute] int% pUpgradeRequired, 
	[OutAttribute] Guid% pguidNewProjectFactory
)

Parameters

bstrFileName
Type: System::String

[in] Project file of project to update.

fUpgradeFlag
Type: System::UInt32

[out] Upgrade types specified by the __VSPPROJECTUPGRADEVIAFACTORYFLAGS enumeration. Only one may be specified.

bstrCopyLocation
Type: System::String

[in] Location of the copy upgrade, or the backup copy location.

pbstrUpgradedFullyQualifiedFileName
Type: System::String%

[out] Copy upgrade will have a different path - others may change the project name.

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

[in] A IVsUpgradeLogger interface to the upgrade logger.

pUpgradeRequired
Type: System::Int32%

[out] true if the project needs upgrading. false if the project is already up-to-date.

pguidNewProjectFactory
Type: System::Guid%

[out] If a different project factory is used to create the upgraded project, the GUID should be returned here.

Return Value

Type: System::Int32
If the method succeeds, it returns S_OK. If it fails, it returns an error code.

COM Signature

From vsshell80.idl:

[C++]

HRESULT UpgradeProject(
    [in]  BSTR               bstrFileName,
    [in]  VSPUVF_FLAGS     * fUpgradeFlags,
    [in]  BSTR               bstrCopyLocation,
    [out] BSTR *             pbstrUpgradedFullyQualifiedFileName,
    [in]  IVsUpgradeLogger * pLogger,
    [out] BOOL             * pUpgradeRequired,
    [out] GUID             * pguidNewProjectFactory,
);

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft