ITextDocument.Save Method
Saves the contents of the TextBuffer to the FilePath.
Namespace: Microsoft.VisualStudio.Text
Assembly: Microsoft.VisualStudio.Text.Data (in Microsoft.VisualStudio.Text.Data.dll)
Syntax
'宣言
Sub Save
void Save()
void Save()
abstract Save : unit -> unit
function Save()
Exceptions
Exception | Condition |
---|---|
InvalidOperationException | This object is in the middle of raising events. |
UnauthorizedAccessException | An access error occurred during file save. |
IOException | An I/O error occurred during file save. |
ObjectDisposedException | This object has been disposed. |
Remarks
If the save operation fails, the value of IsDirty remains unchanged.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.