What is the difference between Savedialog and Filesavedialog in Delphi?

Asked

Viewed 1,768 times

1

I’ve used both components, both Savedialog and Filesavedialog for the same tasks, without noticing any difference between them, except that Filesavedialog is not compatible with Windows XP, the coexistence of the two components was feathered a whim of the Embarcadero or they possess differentiated utilities among themselves?

  • I searched the Delphi documentation and found only Savedialog. Which version is Tfilesavedialog?

1 answer

3


The difference is that TSaveDialog uses standard windows and TFileSaveDialog uses the visual of Vista.

According to the website http://docs.embarcadero.com the following information:

Tsavedialog

TSaveDialog shows a modal dialog window to select the file name and save it. The dialog window does not appear during execution until it is activated by a call to the execution method.

When the user clicks Save dialog window closes and saves the file name in the property FileName.

TSaveDialog is extended from TOpenDialog which is extended from TCommomDialog

Tfilesavedialog

It is a class for Vista window style. This class is extended from TCustomFileSaveDialog, this lets you create windows with the Windows Vista style CLSID_FileSaveDialog and implements the interface of IFileSaveDialog

TFileSaveDialog is extended from TCustomFileSaveDialog which is extended from TCustomFileDialog.

Tcustomfiledialog

Window to open and save files, this abstract base class extends to the file dialog windows for Microsoft Windows Vista style.

Note: In the new versions of Delphi you can use TSaveDialog, because apparently it detects the operating system and switches to the windows system of the same.

  • So it all comes down to appearances?

  • @Evertonbruno believe it is more than appearance, the windows system from the view on has buttons and some more functions, note that it seems that in the new versions of Delphi functions like TSaveDialog already detect the system and use the windows system of the current operating system, thus giving compatibility to older systems (I believe).

  • Thanks for the information, also unknown and could not find in the documentation.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.