Sdílet prostřednictvím


SimpleSyncServices.RemoveItemFromReplica Method

Removes metadata for an item from a replica, but not the item itself.

Namespace: Microsoft.Synchronization.SimpleProviders
Assembly: Microsoft.Synchronization.SimpleProviders (in microsoft.synchronization.simpleproviders.dll)

Syntax

'Declaration
Public Function RemoveItemFromReplica ( _
    key As ItemFieldDictionary _
) As Boolean
'Usage
Dim instance As SimpleSyncServices
Dim key As ItemFieldDictionary
Dim returnValue As Boolean

returnValue = instance.RemoveItemFromReplica(key)
public bool RemoveItemFromReplica (
    ItemFieldDictionary key
)
public:
bool RemoveItemFromReplica (
    ItemFieldDictionary^ key
)
public boolean RemoveItemFromReplica (
    ItemFieldDictionary key
)
public function RemoveItemFromReplica (
    key : ItemFieldDictionary
) : boolean

Parameters

Return Value

true if the item is found and metadata is removed. Otherwise false.

Exceptions

Exception type Condition

SimpleProviderInvalidOperationException

BeginRemoveItemsFromReplica was not called before this method was called.

Remarks

The item will be re-enumerated as a newly created item during a subsequent synchronization session.

BeginRemoveItemsFromReplica must be called to start a transaction before RemoveItemFromReplica is called. Items that are removed by calling RemoveItemFromReplica are not committed until EndRemoveItemsFromReplica is called after all calls to RemoveItemFromReplica are finished.

See Also

Reference

SimpleSyncServices Class
SimpleSyncServices Members
Microsoft.Synchronization.SimpleProviders Namespace