Share via


ContentIterator.ProcessFilesInFolder method (SPFolder, Boolean, ContentIterator.FileProcessor, ContentIterator.FileProcessorErrorCallout)

Iterates over items in a folder.

Namespace:  Microsoft.Office.Server.Utilities
Assembly:  Microsoft.Office.Server (in Microsoft.Office.Server.dll)

Syntax

'Declaration
Public Sub ProcessFilesInFolder ( _
    folder As SPFolder, _
    fRecursive As Boolean, _
    fileProcessor As ContentIterator.FileProcessor, _
    errorCallout As ContentIterator.FileProcessorErrorCallout _
)
'Usage
Dim instance As ContentIterator
Dim folder As SPFolder
Dim fRecursive As Boolean
Dim fileProcessor As ContentIterator.FileProcessor
Dim errorCallout As ContentIterator.FileProcessorErrorCallout

instance.ProcessFilesInFolder(folder, _
    fRecursive, fileProcessor, errorCallout)
public void ProcessFilesInFolder(
    SPFolder folder,
    bool fRecursive,
    ContentIterator.FileProcessor fileProcessor,
    ContentIterator.FileProcessorErrorCallout errorCallout
)

Parameters

  • fRecursive
    Type: System.Boolean

    If true, iterate over all items in all subfolders.

Remarks

This method does paged queries to fetch the requested files and calls fileProcessor for each file and calls the optional errorCallout if an exception occurs while processing a file.

See also

Reference

ContentIterator class

ContentIterator members

ProcessFilesInFolder overload

Microsoft.Office.Server.Utilities namespace