IVsProjectFactory.CanCreateProject Method

Determines whether a new project can be created.

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

Syntax

声明
Function CanCreateProject ( _
    pszFilename As String, _
    grfCreateFlags As UInteger, _
    <OutAttribute> ByRef pfCanCreate As Integer _
) As Integer
用法
Dim instance As IVsProjectFactory
Dim pszFilename As String
Dim grfCreateFlags As UInteger
Dim pfCanCreate As Integer
Dim returnValue As Integer

returnValue = instance.CanCreateProject(pszFilename, _
    grfCreateFlags, pfCanCreate)
int CanCreateProject(
    string pszFilename,
    uint grfCreateFlags,
    out int pfCanCreate
)
int CanCreateProject(
    [InAttribute] String^ pszFilename, 
    [InAttribute] unsigned int grfCreateFlags, 
    [OutAttribute] int% pfCanCreate
)
abstract CanCreateProject : 
        pszFilename:string * 
        grfCreateFlags:uint32 * 
        pfCanCreate:int byref -> int 
function CanCreateProject(
    pszFilename : String, 
    grfCreateFlags : uint, 
    pfCanCreate : int
) : int

Parameters

  • pszFilename
    Type: System.String
    [in] File name of the project you are trying to create.
  • pfCanCreate
    Type: System.Int32%
    [out] true if the project can be created.

Return Value

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

Remarks

COM Signature

From vsshell.idl:

HRESULT IVsProjectFactory::CanCreateProject(
   [in] LPCOLESTR pszFilename,
   [in] VSCREATEPROJFLAGS grfCreateFlags,
   [out] BOOL *pfCanCreate
);

.NET Framework Security

See Also

Reference

IVsProjectFactory Interface

IVsProjectFactory Members

Microsoft.VisualStudio.Shell.Interop Namespace