Name
SaveFileDialog
Synopsis
This FileDialog
class provides a means for a user
to select a filename with which to save a file. You can choose to
display a prompt if the file does not exist by setting the
CreatePrompt
property.
OverwritePrompt
will do the same if a file with
the selected name does exist. The OpenFile()
method will (create and) open a file Stream
for
the selected filename.
public sealed class SaveFileDialog : FileDialog { // Public Constructors public SaveFileDialog(); // Public Instance Properties public bool CreatePrompt{set; get; } public bool OverwritePrompt{set; get; } // Public Instance Methods public Stream OpenFile(); public override void Reset(); // overrides FileDialog }
Hierarchy
System.Object
→ System.MarshalByRefObject → System.ComponentModel.Component(System.ComponentModel.IComponen,
System.IDisposable)
→ CommonDialog → FileDialog → SaveFileDialog
Get .NET Windows Forms in a Nutshell now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.