Share via


CrossListQueryCache.GetSiteDataResults method (SPWeb, Boolean)

Gets the results of the passed in query parameter on the specified web or list.

Namespace:  Microsoft.SharePoint.Publishing
Assembly:  Microsoft.SharePoint.Publishing (in Microsoft.SharePoint.Publishing.dll)

Syntax

'Declaration
Public Function GetSiteDataResults ( _
    web As SPWeb, _
    useSpQueryOnList As Boolean _
) As SiteDataResults
'Usage
Dim instance As CrossListQueryCache
Dim web As SPWeb
Dim useSpQueryOnList As Boolean
Dim returnValue As SiteDataResults

returnValue = instance.GetSiteDataResults(web, _
    useSpQueryOnList)
public SiteDataResults GetSiteDataResults(
    SPWeb web,
    bool useSpQueryOnList
)

Parameters

  • useSpQueryOnList
    Type: System.Boolean

    Whether to run the query against a list.

Return value

Type: Microsoft.SharePoint.Publishing.SiteDataResults
A SiteDataResults object that contains the results of running the query.

Remarks

This version of GetSiteDataResults uses object's member SPSiteDataQuery.

The query will be run against an SPList object if the useSpQueryOnList parameter is set to true. Otherwise, the query will be run against a web.

See also

Reference

CrossListQueryCache class

CrossListQueryCache members

GetSiteDataResults overload

Microsoft.SharePoint.Publishing namespace