Export (0) Print
Expand All

FileDialog.ValidateNames Property

Gets or sets a value indicating whether the dialog box accepts only valid Win32 file names.

[Visual Basic]
Public Property ValidateNames As Boolean
[C#]
public bool ValidateNames {get; set;}
[C++]
public: __property bool get_ValidateNames();
public: __property void set_ValidateNames(bool);
[JScript]
public function get ValidateNames() : Boolean;
public function set ValidateNames(Boolean);

Property Value

true if the dialog box accepts only valid Win32 file names; otherwise, false. The default value is true.

Remarks

If the edit control contains anything but spaces when the user clicks OK, the dialog returns the file name, whether it is valid or not. No default extension is added to the text.

Requirements

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family

.NET Framework Security: 

See Also

FileDialog Class | FileDialog Members | System.Windows.Forms Namespace

Show:
© 2014 Microsoft