TXTextControl.WPF.TextControl.Save Method

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

Save()

Opens a file save dialogbox and saves the complete contents of a document in a file.

[C#]
public DialogResult Save();
[Visual Basic]
Public Function Save() As DialogResult

Save(StreamType)

Opens a file save dialogbox and saves the complete contents of a document in a file with the specified format.

[C#]
public DialogResult Save(StreamType streamType);
[Visual Basic]
Public Function Save(ByVal streamType As StreamType) As DialogResult
Member Description
streamType

Specifies one of the StreamType values.

Save(String, StreamType)

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

[C#]
public void Save(string path, StreamType streamType);
[Visual Basic]
Public Sub Save(ByVal path As String, ByVal streamType As StreamType)
Member 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.

Save(FileStream, StreamType)

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

[C#]
public void Save(System.IO.FileStream fileStream, StreamType streamType);
[Visual Basic]
Public Sub Save(ByVal fileStream As System.IO.FileStream, ByVal streamType As StreamType)
Member 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.

Save(Byte[], BinaryStreamType)

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

[C#]
public void Save(out byte[] binaryData, BinaryStreamType binaryStreamType);
[Visual Basic]
Public Sub Save(ByRef binaryData As Byte(), ByVal binaryStreamType As BinaryStreamType)
Member 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.

Save(String, StringStreamType)

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

[C#]
public void Save(out string stringData, StringStreamType stringStreamType);
[Visual Basic]
Public Sub Save(ByRef stringData As String, ByVal stringStreamType As StringStreamType)
Member 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.

Save(StreamType, SaveSettings)

Opens a file save dialogbox and saves the complete contents of a document in a file with the specified format and special settings.

[C#]
public DialogResult Save(StreamType streamType, SaveSettings saveSettings);
[Visual Basic]
Public Function Save(ByVal streamType As StreamType, ByVal saveSettings As SaveSettings) As DialogResult
Member Description
streamType

Specifies one of the StreamType values.

saveSettings

Specifies a SaveSettings object with additional information and settings for the save operation.

Save(String, StreamType, SaveSettings)

Saves the complete contents of a document in the specified file using the specified format and special settings.

[C#]
public void Save(string path, StreamType streamType, SaveSettings saveSettings);
[Visual Basic]
Public Sub Save(ByVal path As String, ByVal streamType As StreamType, ByVal saveSettings As SaveSettings)
Member 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.

saveSettings

Specifies a SaveSettings object with additional information and settings for the save operation.

Save(FileStream, StreamType, SaveSettings)

Saves the complete contents of a document in the specified file stream using the specified format and special settings.

[C#]
public void Save(System.IO.FileStream fileStream, StreamType streamType, SaveSettings saveSettings);
[Visual Basic]
Public Sub Save(ByVal fileStream As System.IO.FileStream, ByVal streamType As StreamType, ByVal saveSettings As SaveSettings)
Member 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.

saveSettings

Specifies a SaveSettings object with additional information and settings for the save operation.

Save(Byte[], BinaryStreamType, SaveSettings)

Saves the complete contents of a document in the specified byte array using the specified format and special settings.

[C#]
public void Save(out byte[] binaryData, BinaryStreamType binaryStreamType, SaveSettings saveSettings);
[Visual Basic]
Public Sub Save(ByRef binaryData As Byte(), ByVal binaryStreamType As BinaryStreamType, ByVal saveSettings As SaveSettings)
Member 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.

saveSettings

Specifies a SaveSettings object with additional information and settings for the save operation.

Save(String, StringStreamType, SaveSettings)

Saves the complete contents of a document as a string using the specified format and special settings.

[C#]
public void Save(out string stringData, StringStreamType stringStreamType, SaveSettings saveSettings);
[Visual Basic]
Public Sub Save(ByRef stringData As String, ByVal stringStreamType As StringStreamType, ByVal saveSettings As SaveSettings)
Member 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.

saveSettings

Specifies a SaveSettings object with additional information and settings for the save operation.

Return Value

The implementations which open a dialog box return a WPF.DialogResult value.

See Also