IVsWebProject::AddNewWebItem Method (UInt32, VSADDITEMOPERATION, String^, String^, UInt32, String^, IntPtr, array<VSADDRESULT>^)
Visual Studio 2015
Adds a new Web item to the project.
Assembly: Microsoft.VisualStudio.Shell.Interop.8.0 (in Microsoft.VisualStudio.Shell.Interop.8.0.dll)
int AddNewWebItem( unsigned int itemidLoc, VSADDITEMOPERATION dwAddItemOperation, String^ pszItemName, String^ pszFileTemplate, unsigned int options, String^ pszSelectedLanguage, IntPtr hwndDlgOwner, array<VSADDRESULT>^ pResult )
Parameters
- itemidLoc
-
Type:
System::UInt32
[in] Folder to which the item is to be added.
- dwAddItemOperation
-
Type:
Microsoft.VisualStudio.Shell.Interop::VSADDITEMOPERATION
[in] Add item operation. Only VSADDITEMOP_CLONEFILE and VSADDITEMOP_RUNWIZARD are valid
- pszItemName
-
Type:
System::String^
[in] Name of the item.
- pszFileTemplate
-
Type:
System::String^
[in] Path to the template the user selected.
- options
-
Type:
System::UInt32
[in] The options checked on the dialog for the item.
- pszSelectedLanguage
-
Type:
System::String^
[in] String selected from the languages dropdown (can be null).
- hwndDlgOwner
-
Type:
System::IntPtr
[in] Handle to the Add New Web Item dialog.
- pResult
-
Type:
array<Microsoft.VisualStudio.Shell.Interop::VSADDRESULT>^
[out] Pointer to the VSADDRESULT enumeration indicating whether the item was successfully added to the project.
Return Value
Type: System::Int32If the method succeeds, it returns S_OK. If it fails, it returns an error code.
From vsshell80.idl:
HRESULT IVsWebProject::AddNewWebItem( [in] VSITEMID itemidLoc, [in] VSADDITEMOPERATION dwAddItemOperation, [in] LPCOLESTR pszItemName, [in] LPCOLESTR pszFileTemplate, [in] VSADDNEWWEBITEMOPTIONS options, [in] LPCOLESTR pszSelectedLanguage, [in] HWND hwndDlgOwner, [out, retval] VSADDRESULT * pResult );
Show: