XQuery.Serialize Method (string)XQuery.Serialize Method (String)XQuery::Serialize Method (String^)

Serializes the result of the query to the specified file.

Syntax

Public Sub Serialize( _
    outputFileName As String _
)
public void Serialize(
    string outputFileName
)
public:
void Serialize(
    String^ outputFileName
)
 

Parameters

outputFileName

Type: System.StringSystem.StringSystem::String^

The name of the file to which the result of the query will be written. The outputFileName must be a file system path.

Exceptions

ExceptionCondition
ArgumentNullExceptionArgumentNullExceptionArgumentNullException outputFileName is null a null reference (Nothing in Visual Basic) nullptr.
InvalidOperationExceptionInvalidOperationExceptionInvalidOperationExceptionThe query is an updating expression.
XdmExceptionXdmExceptionXdmException A dynamic error was encountered while evaluating the query.