XdmWriter.Create Method (string, XmlNameTable)XdmWriter.Create Method (String, XmlNameTable)XdmWriter::Create Method (String^, XmlNameTable^)

Creates an XdmWriterXdmWriterXdmWriter instance using the specified file and XML name table.

Syntax

Public Shared Function Create( _
    outputFileName As String, _
    nameTable As System.Xml.XmlNameTable _
) As XdmWriter
public static XdmWriter Create(
    string outputFileName,
    System.Xml.XmlNameTable nameTable
)
public:
static XdmWriter^ Create(
    String^ outputFileName, 
    System.Xml::XmlNameTable^ nameTable
)
 

Parameters

outputFileName

Type: System.StringSystem.StringSystem::String^

The name of the file to which you want to write. The outputFileName must be a file system path.

nameTable

Type: System.Xml.XmlNameTableSystem.Xml.XmlNameTableSystem.Xml::XmlNameTable^

The name table used for element names.

Exceptions

ExceptionCondition
ArgumentNullExceptionArgumentNullExceptionArgumentNullException outputFileName or nameTable is null a null reference (Nothing in Visual Basic) nullptr.
XdmExceptionXdmExceptionXdmExceptionThere is an error with the serialization configuration.

Remarks

An XdmWriterSettingsXdmWriterSettingsXdmWriterSettings object with default settings is used to create the writer. If you wish to specify the serialization parameters on the created writer, use the overload that takes an XdmWriterSettingsXdmWriterSettingsXdmWriterSettings object as one of its arguments, and pass in an XdmWriterSettingsXdmWriterSettingsXdmWriterSettings object with the correct settings.