Share via


ReportingService2005.DeleteItem(String) Method

Definition

Deletes a specified item from the report server database.

public:
 void DeleteItem(System::String ^ Item);
public void DeleteItem (string Item);
member this.DeleteItem : string -> unit
Public Sub DeleteItem (Item As String)

Parameters

Item
String

The fully qualified URL of the item. The item to delete can be an EditSessionID.

Remarks

The table below shows header and permissions information on this operation.

SOAP Headers (In) BatchHeaderValue

(Out) ServerInfoHeaderValue
Required Permissions Depends on the item type.

- Folder: Delete
- Report, LinkedReport: Delete
- Resource: Delete
- DataSource: Delete
- Model: Delete

If the item contains any child items, you must also have the respective Delete permission for each child item.

The length of the Item parameter cannot exceed 260 characters; otherwise, a SOAP exception is thrown with the error code rsItemLengthExceeded.

The Item parameter cannot be null or empty or contain the following reserved characters: : ? ; @ & = + $ , \ * > < | . ". You can use the forward slash character (/) to separate items in the full path name of the folder, but you cannot use it at the end of the folder name.

The DeleteItem method not only deletes the specified item from the report server database, it also deletes additional items, such as the subscriptions, schedules, and snapshots that are associated with the item.

If My Reports is enabled, a SOAP exception is thrown with the error code rsCannotDeleteReservedFolder if you attempt to delete the /My Reports or /Users Folders folder. You can check the properties of any item by using the GetProperties method. If the item has a Reserved property set to a value of true, the item cannot be deleted.

Deleting an item in the report server database modifies the ModifiedByand ModifiedDate properties of the parent item.

Applies to