Click or drag to resize

FileOperationNewItem Method (ShellItemIdList, FileAttributes, String, String, Boolean)

Declares a new item that is to be created in a specified location.

Namespace:  ShellBoost.Core.Utilities
Assembly:  ShellBoost.Core (in ShellBoost.Core.dll) Version: 1.8.3.0
Syntax
C#
public int NewItem(
	ShellItemIdList folderIdl,
	FileAttributes attributes,
	string name,
	string templateName = null,
	bool throwOnError = true
)

Parameters

folderIdl
Type: ShellBoost.CoreShellItemIdList
The folder PIDL.
attributes
Type: System.IOFileAttributes
The attributes.
name
Type: SystemString
The name of the new item.
templateName (Optional)
Type: SystemString
The template name. Pass null to specify a new, blank file.
throwOnError (Optional)
Type: SystemBoolean
if set to true errors may be throw in case of Windows Shell errors.

Return Value

Type: Int32
The result of Windows Shell last operation.
Exceptions
ExceptionCondition
ArgumentNullExceptionfolderIdl or name is null.
See Also