This property sets the folder initially displayed by the OpenFileDialog and SaveFileDialog methods.

[Visual Basic] Public Property FilePath As String
[C#] public string FilePath {get; set;}

Property Value

The FilePath is the folder name

Explanation

The FilePath property sets the folder initially displayed by the OpenFileDialog and SaveFileDialog methods.

When you execute the OpenFileDialog and SaveFileDialog methods, the "Open" dialog box and "Save" dialog box will be displayed. The FilePath property allows you to set the folder that is accessed when the "Open" dialog box and "Save" dialog box are displayed.

When setting the FileExtension property, start with the file explanation followed by a "|" symbol as a delimeter and the the file extensions to be displayed. When listing multiple file extensions, use a comma (;) to delimit them. If an empty string ("") is set into the FileExtension property then the file types will be "all files". If an empty string is set into the FilePath property, then the current direct directory will be displayed when the dialog opens.

There is no distinction made between upper case or lower case letters so that "BMP" is treated as the same as "bmp".

Example

The code below illustlates how to set the default folder to "C:\Images" and to set the file types to "BMP", "JPG and PNG", and "All Files":

[Visual Basic.NET]
ImageKit1.File.FilePath = "c:\images"
ImageKit1.File.FileExtension = "Bitmap files|*.bmp|Jpeg,Png files|*.jpg;*.png|All Files|*.*"

[Visual C#.NET]
ImageKit1.File.FilePath = "c:\\Images";
ImageKit1.File.FileExtension = "Bitmap files|*.bmp|Jpeg,Png files|*.jpg;*.png|All Files|*.*"; 

See Also

ImageKit.File Members | Newtone.ImageKit.Wpf.ImageKit

The ImageKit WPF is created by Newtone Corporation