TXTextControl.Web.TextControl.SaveText Method

Saves the complete contents of a document with the specified format.

SaveText(String, StreamType)

Saves the complete contents of a document in the specified file with the specified format.

[C#]
public void SaveText(string path,  Web.StreamType streamType);
[Visual Basic]
Public Sub SaveText(ByVal path As String, ByVal streamType As  Web.StreamType)
Parameter Description
path

Specifies a file into which the data is saved. If the file does not exist it is created. If the file exists its contents are overwritten.

streamType

Specifies one of the StreamType values.

SaveText(FileStream, StreamType)

Saves the complete contents of a document in the specified file stream with the specified format.

[C#]
public void SaveText(System.IO.FileStream fileStream,  Web.StreamType streamType);
[Visual Basic]
Public Sub SaveText(ByVal fileStream As System.IO.FileStream, ByVal streamType As  Web.StreamType)
Parameter Description
fileStream

Specifies a file into which the data is saved. The data is saved at the stream's current position.

streamType

Specifies one of the StreamType values.

SaveText(Byte[], BinaryStreamType)

Saves the complete contents of a document in the specified byte array with the specified format.

[C#]
public void SaveText(out byte[] binaryData, Web.BinaryStreamType binaryStreamType);
[Visual Basic]
Public Sub SaveText(ByRef binaryData As Byte(), ByVal binaryStreamType As Web.BinaryStreamType)
Parameter Description
binaryData

Specifies a byte array into which the data is saved. No memory needs to be allocated through the caller.

binaryStreamType

Specifies one of the BinaryStreamType values.

SaveText(String, StringStreamType)

Saves the complete contents of a document as a string with the specified format.

[C#]
public void SaveText(out string stringData, Web.StringStreamType stringStreamType);
[Visual Basic]
Public Sub SaveText(ByRef stringData As String, ByVal stringStreamType As Web.StringStreamType)
Parameter Description
stringData

Specifies a string into which the data is saved. No memory needs to be allocated through the caller.

stringStreamType

Specifies one of the StringStreamType values.

See Also