SPItemEventReceiver.ItemCheckingOut Method (Microsoft.SharePoint)
SPItemEventReceiver.ItemCheckingOut Method (Microsoft.SharePoint)
Synchronous Before event that occurs after an item is checked out.

Namespace: Microsoft.SharePoint
Assembly: Microsoft.SharePoint (in microsoft.sharepoint.dll)
Syntax

'Usage

Dim instance As SPItemEventReceiver
Dim properties As SPItemEventProperties

instance.ItemCheckingOut(properties)

'Declaration

Public Overridable Sub ItemCheckingOut ( _
    properties As SPItemEventProperties _
)

Parameters

properties
See Also

Community Content

This eventReceiver does not work
Added by:Noelle Mallory - MSFT

Each time the itemCheckingOut eventReceiver is fired, the following error message is raised:

"Attempted to read or write protected memory. This is often an indication that other memory is corrupt. "

No known workaround at this time, to my knowledge.

ItemCheckingOut not fire
Added by:jab_be
ItemcheckingOut is not fire when Require Check Out property is set to Yes !!!
Canceling a checkout generates "Attempted to read or write protected memory." error.
Added by:Michael Washam - MSFT

Description:

When attempting to cancel an item checkout in the ItemCheckingOut event handler the error "Attempted to read or write protected memory. This is often an indication that other memory is corrupt." is shown to the user. This is a known issue with WSS 3.0 however, there is a workaround. You should set the Status property to SPEventReceiverStatus.CancelNoError instead of SPEventReceiverStatus.CancelWithError or setting properties.Cancel = true;

C# Version

public override void ItemCheckingOut(SPItemEventProperites properties)
{
// Logic to decide checkout status here
properties.Status = SPEventReceiverStatus.CancelNoError;
}



VB Version

Public Overrides Sub ItemCheckingOut(ByVal properties as SPItemEventProperties)
properties.Status = SPEventReceiverStatus.CancelNoError
End Sub
© 2009 Microsoft Corporation. All rights reserved.   Terms of Use | Trademarks | Privacy Statement
Page view tracker
Rate the Lightweight library
x
Lightweight builds on ScriptFree (loband) by adding features you've requested: a SearchBox and default code language selection.
Do you like the SearchBox?
Do you like the tabbed code blocks?
How useful is this topic?
Tell us more.
Thanks
x
You're helping to improve MSDN Online.
Feedback
Switch View
Classic
Lightweight Beta
ScriptFree
Switch View