ItemOperations::PromptToSave Property

 

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

Namespace:   EnvDTE
Assembly:  EnvDTE (in EnvDTE.dll)

property vsPromptResult PromptToSave {
	vsPromptResult get();
}

Property Value

Type: EnvDTE::vsPromptResult

A vsPromptResult value describing the user's action after displaying a dialog box.

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 open documents.

Sub PromptToSaveExample()
   Dim myVal As EnvDTE.vsPromptResult
   myVal = DTE.ItemOperations().PromptToSave()
   MsgBox(myVal.ToString)
End Sub
Return to top
Show: