log4net SDK Reference |

# Transform.WriteEscapedXmlString Method

Write a string to an XmlWriter

[Visual Basic]
Public Shared Sub WriteEscapedXmlString( _
ByVal writer As XmlWriter, _
ByVal textData As String, _
ByVal invalidCharReplacement As String _
)
[C#]
public static void WriteEscapedXmlString(
XmlWriter writer,
string textData,
string invalidCharReplacement
);

#### Parameters

writer
  the writer to write to
textData
  the string to write
invalidCharReplacement
  The string to replace non XML compliant chars with

#### Remarks

The test is escaped either using XML escape entities or using CDATA sections.

#### See Also

Transform Class | log4net.Util Namespace