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

Visual Basic (Declaration)
Public Overridable Sub ItemCheckingOut ( _
    properties As SPItemEventProperties _
)
Visual Basic (Usage)
Dim instance As SPItemEventReceiver
Dim properties As SPItemEventProperties

instance.ItemCheckingOut(properties)
C#
public virtual void ItemCheckingOut (
    SPItemEventProperties properties
)

Parameters

properties
See Also

Tags :


Community Content

Noelle Mallory - MSFT
This eventReceiver does not work

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.


jab_be
ItemCheckingOut not fire
ItemcheckingOut is not fire when Require Check Out property is set to Yes !!!
Tags :

Michael Washam - MSFT
Canceling a checkout generates "Attempted to read or write protected memory." error.

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

Page view tracker