Export (0) Print
Expand All
Expand Minimize

SPContext.SetCachedField Delegate

Implements a callback to set cached field values.

Namespace:  Microsoft.SharePoint
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Available in Sandboxed Solutions: No

public delegate void SetCachedField(
	string fieldName,
	string cachedFieldValue
)

Parameters

fieldName
Type: System.String

A string that specifies the name of the field to be cached.

cachedFieldValue
Type: System.String

A string that specifies the cached field output. This parameter can contain an empty string if there is nothing to display.

To speed up rendering of field controls on non-Display form pages, you can implement a callback that caches the values. For security reasons, this callback can be used in Display mode only, and cannot be called for certain field controls (for example, for a Lookup field to a security-trimmed list). It is best practice to avoid setting callbacks for draft versions or for pages that are checked out.

Show:
© 2014 Microsoft