Export (0) Print
Expand All
ID
Top
Expand Minimize

PromptToSave Property

Visual Studio .NET 2003

Displays all unsaved files and allows the user to save one or more of them.

[Visual Basic .NET]
Public ReadOnly Property PromptToSave() As vsPromptResult
[Visual Basic 6]
Property Get PromptToSave() As vsPromptResult
[C++]
HRESULT __stdcall get_PromptToSave(
   /* [out, retval] */ vsPromptResult* retVal
);
[C#]
public vsPromptResult PromptToSave {get;}
[JScript .NET]
public function get PromptToSave() : vsPromptResult

Return Value

Returns a vsPromptResult value describing the user's action after displaying a dialog box to them.

Remarks

PromptToSave allows the user to save open documents similar to when the IDE is closed. Calling PromptToSave, however, does not mean that all documents are automatically saved. Rather, it gives the user the opportunity to save some or all of the open documents.

Example

Sub PromptToSaveExample()
   Dim myVal As EnvDTE.vsPromptResult
   myVal = DTE.ItemOperations().PromptToSave()
   MsgBox(myVal.ToString)
End Sub

See Also

Applies To: ItemOperations Object

Show:
© 2014 Microsoft