[.Net Tools] Windows API CodePack from Nuget

[.Net Tools] Windows API CodePack from Nuget

這是將 Windows API 包裝起來的元件,可以從 Nuget 下載來使用

image

 

參考資料

http://blogs.windows.com/windows/archive/b/developers/archive/2009/05/18/windows-7-managed-code-apis.aspx

http://blogs.msdn.com/b/windowssdk/archive/2009/06/12/windows-api-code-pack-for-microsoft-net-framework.aspx

http://www.codeproject.com/Articles/109403/Windows-API-Code-Pack-v-Released

 

簡單範例

Windows API CodePack 所提供的 CommonOpenFileDialog

{
    Microsoft.WindowsAPICodePack.Dialogs.CommonOpenFileDialog folder =
        new Microsoft.WindowsAPICodePack.Dialogs.CommonOpenFileDialog();
    folder.ShowDialog();
}

 

CommonOpenFileDialog 運行結果如下圖:

image

 

 

.NET 所提供的 FolderBrowserDialog 類別

{
    FolderBrowserDialog folder = new FolderBrowserDialog();
    folder.ShowDialog();
}

 

運行結果如下圖:

image


本文出自:

若有謬誤,煩請告知,新手發帖請多包涵


Microsoft MVP Award 2010~2017 C# 第四季
Microsoft MVP Award 2018~2022 .NET

Image result for microsoft+mvp+logo