Hinweis
Für den Zugriff auf diese Seite ist eine Autorisierung erforderlich. Sie können versuchen, sich anzumelden oder das Verzeichnis zu wechseln.
Für den Zugriff auf diese Seite ist eine Autorisierung erforderlich. Sie können versuchen, das Verzeichnis zu wechseln.
Generates a unique project name, given a root project name.
Namespace: Microsoft.VisualStudio.Shell.Interop
Assembly: Microsoft.VisualStudio.Shell.Interop (in Microsoft.VisualStudio.Shell.Interop.dll)
Syntax
'Declaration
Function GenerateUniqueProjectName ( _
lpszRoot As String, _
<OutAttribute> ByRef pbstrProjectName As String _
) As Integer
'Usage
Dim instance As IVsSolution2
Dim lpszRoot As String
Dim pbstrProjectName As String
Dim returnValue As Integer
returnValue = instance.GenerateUniqueProjectName(lpszRoot, _
pbstrProjectName)
int GenerateUniqueProjectName(
string lpszRoot,
out string pbstrProjectName
)
int GenerateUniqueProjectName(
[InAttribute] String^ lpszRoot,
[OutAttribute] String^% pbstrProjectName
)
abstract GenerateUniqueProjectName :
lpszRoot:string *
pbstrProjectName:string byref -> int
function GenerateUniqueProjectName(
lpszRoot : String,
pbstrProjectName : String
) : int
Parameters
- lpszRoot
Type: System.String
[in] Root project name. Passing in nulla null reference (Nothing in Visual Basic) causes the environment to use an appropriate default value for the name, like Project.
- pbstrProjectName
Type: System.String%
[out] Pointer to the project name based on the root project name specified in the lpszRoot parameter. This value is unique within the solution.
Return Value
Type: System.Int32
If the method succeeds, it returns S_OK. If it fails, it returns an error code.
Implements
IVsSolution.GenerateUniqueProjectName(String, String%)
Remarks
COM Signature
From vsshell.idl:
HRESULT IVsSolution2::GenerateUniqueProjectName(
[in] LPCOLESTR lpszRoot,
[out] BSTR *pbstrProjectName
);
This method is typically called by wizards. When you call the CreateProject method to create a project, the environment handles creating a unique project name through the New Project dialog box.
.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.