FileNameEditor 類別
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
重要
此 API 不符合 CLS 規範。
提供選取檔名的使用者介面。
public ref class FileNameEditor : System::Drawing::Design::UITypeEditor
C#
public class FileNameEditor : System.Drawing.Design.UITypeEditor
C#
[System.CLSCompliant(false)]
public class FileNameEditor : System.Drawing.Design.UITypeEditor
type FileNameEditor = class
inherit UITypeEditor
[<System.CLSCompliant(false)>]
type FileNameEditor = class
inherit UITypeEditor
Public Class FileNameEditor
Inherits UITypeEditor
- 繼承
- 屬性
下列程式碼範例會使用 EditorAttribute ,將 與 屬性產生關聯 FileNameEditor 。
public:
[EditorAttribute(System::ComponentModel::Design::CollectionEditor::typeid,
System::Drawing::Design::UITypeEditor::typeid)]
property String^ testFilename
{
String^ get()
{
return filename;
}
void set( String^ value )
{
filename = value;
}
}
private:
String^ filename;
C#
[EditorAttribute(typeof(System.Windows.Forms.Design.FileNameEditor), typeof(System.Drawing.Design.UITypeEditor))]
public string testFilename
{
get
{
return filename;
}
set
{
filename = value;
}
}
private string filename;
<EditorAttribute(GetType(System.Windows.Forms.Design.FileNameEditor), GetType(System.Drawing.Design.UITypeEditor))> _
Public Property testFilename() As String
Get
Return filename
End Get
Set
filename = value
End Set
End Property
Private filename As String
FileNameEditor 提供檔案名選取和編輯的檔案選取對話方塊。
您可以繼承自這個類別,以提供對話方塊和您自己的檔案清單篩選副檔名的標題。
File |
初始化 FileNameEditor 類別的新執行個體。 |
Is |
取得值,表示使用者是否能夠調整下拉式編輯器的大小。 (繼承來源 UITypeEditor) |
產品 | 版本 |
---|---|
.NET Framework | 1.1, 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
Windows Desktop | 3.0, 3.1, 5, 6, 7, 8, 9, 10 |