{"id":102051,"date":"2026-09-08T03:43:18","date_gmt":"2026-09-07T19:43:18","guid":{"rendered":"https:\/\/www.wsisp.com\/helps\/102051.html"},"modified":"2026-09-08T03:43:18","modified_gmt":"2026-09-07T19:43:18","slug":"wpf%ef%bc%9a%e6%96%87%e4%bb%b6-%e6%96%87%e4%bb%b6%e5%a4%b9%e9%80%89%e6%8b%a9%e5%af%b9%e8%af%9d%e6%a1%86","status":"publish","type":"post","link":"https:\/\/www.wsisp.com\/helps\/102051.html","title":{"rendered":"WPF\uff1a\u6587\u4ef6\/\u6587\u4ef6\u5939\u9009\u62e9\u5bf9\u8bdd\u6846"},"content":{"rendered":"<p>\u73af\u5883&#xff1a;  VS2022&#043;.Net Framework4.8<br \/>\nNuGet\u5305&#xff1a;WindowsAPICodePack-Core 1.1.2  &#xff1b;<br \/>\nWindowsAPICodePack-Shell 1.1.1<br \/>\n\u7a0b\u5e8f\u540d&#xff1a;WpfA_OpenFileFolderDemo<\/p>\n<h2>\u4e00\u3001\u529f\u80fd\u6982\u8ff0<\/h2>\n<p>\u8fd9\u662f\u4e00\u4e2aWPF\u7528\u6237\u63a7\u4ef6&#xff0c;\u6f14\u793a\u4e86\u56db\u79cd\u4e0d\u540c\u7684\u6587\u4ef6\u548c\u6587\u4ef6\u5939\u9009\u62e9\u5bf9\u8bdd\u6846&#xff1a;<\/p>\n<ul>\n<li>\u6253\u5f00\u6587\u4ef6\u5bf9\u8bdd\u6846&#xff08;OpenFileDialog&#xff09;&#xff1a;\u4f7f\u7528Win32\u6807\u51c6\u5bf9\u8bdd\u6846\u9009\u62e9\u56fe\u7247\u6587\u4ef6<\/li>\n<li>\u4fdd\u5b58\u6587\u4ef6\u5bf9\u8bdd\u6846&#xff08;SaveFileDialog&#xff09;&#xff1a;\u4f7f\u7528Win32\u6807\u51c6\u5bf9\u8bdd\u6846\u4fdd\u5b58BMP\u56fe\u50cf<\/li>\n<li>\u6587\u4ef6\u5939\u6d4f\u89c8\u5bf9\u8bdd\u6846&#xff08;FolderBrowserDialog&#xff09;&#xff1a;\u4f7f\u7528WinForms\u7ec4\u4ef6\u9009\u62e9\u6587\u4ef6\u5939<\/li>\n<li>\u901a\u7528\u6253\u5f00\u6587\u4ef6\u5bf9\u8bdd\u6846&#xff08;CommonOpenFileDialog&#xff09;&#xff1a;\u4f7f\u7528Windows API Code Pack\u9009\u62e9\u6587\u4ef6\u5939<br \/>\n<img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260907194317-6a9f13d581605.png\" alt=\"\" \/><\/li>\n<\/ul>\n<h2>\u4e8c\u3001\u6280\u672f\u7ec4\u4ef6<\/h2>\n<ul>\n<li>FolderBrowserDialog&#xff1a;\u4f20\u7edf\u6837\u5f0f&#xff0c;\u4f7f\u7528WinForms&#xff0c;\u9700\u8981\u6dfb\u52a0System.Windows.Forms\u5f15\u7528<\/li>\n<li>CommonOpenFileDialog&#xff1a;\u73b0\u4ee3\u5316Vista\u98ce\u683c\u5bf9\u8bdd\u6846&#xff0c;\u901a\u8fc7IsFolderPicker&#061;true\u5207\u6362\u5230\u6587\u4ef6\u5939\u9009\u62e9\u6a21\u5f0f&#xff0c;\u754c\u9762\u66f4\u7f8e\u89c2<\/li>\n<li>\u6dfb\u52a0\u5f15\u7528<br \/>\n\u53f3\u952e\u70b9\u51fb\u9879\u76ee \u2192 \u9009\u62e9 \u201c\u6dfb\u52a0\u201d \u2192 \u201c\u5f15\u7528\u201d<br \/>\n\u5728\u5f15\u7528\u7ba1\u7406\u5668\u4e2d&#xff0c;\u5de6\u4fa7\u9009\u62e9 \u201c\u7a0b\u5e8f\u96c6\u201d \u2192 \u201c\u6846\u67b6\u201d<br \/>\n\u5728\u53f3\u4fa7\u5217\u8868\u4e2d&#xff0c;\u627e\u5230\u5e76\u52fe\u9009&#xff1a;<br \/>\nSystem.Windows.Forms<br \/>\nSystem.Drawing<br \/>\n\u70b9\u51fb \u201c\u786e\u5b9a\u201d<\/li>\n<\/ul>\n<h2>\u4e09\u3001WindowsAPICodePack.Dialogs \u5c5e\u6027\u4e0e\u65b9\u6cd5<\/h2>\n<h3>CommonOpenFileDialog \u4e3b\u8981\u5c5e\u6027<\/h3>\n<table>\n<tr>\u5c5e\u6027\u7c7b\u578b\u8bf4\u660e<\/tr>\n<tbody>\n<tr>\n<td>Title<\/td>\n<td>string<\/td>\n<td>\u5bf9\u8bdd\u6846\u6807\u9898<\/td>\n<\/tr>\n<tr>\n<td>IsFolderPicker<\/td>\n<td>bool<\/td>\n<td>true\u65f6\u9009\u62e9\u6587\u4ef6\u5939&#xff0c;false\u65f6\u9009\u62e9\u6587\u4ef6<\/td>\n<\/tr>\n<tr>\n<td>Multiselect<\/td>\n<td>bool<\/td>\n<td>\u662f\u5426\u5141\u8bb8\u591a\u9009<\/td>\n<\/tr>\n<tr>\n<td>DefaultFileName<\/td>\n<td>string<\/td>\n<td>\u9ed8\u8ba4\u6587\u4ef6\u540d<\/td>\n<\/tr>\n<tr>\n<td>InitialDirectory<\/td>\n<td>string<\/td>\n<td>\u521d\u59cb\u76ee\u5f55<\/td>\n<\/tr>\n<tr>\n<td>FileName<\/td>\n<td>string<\/td>\n<td>\u7528\u6237\u9009\u62e9\u7684\u6587\u4ef6\/\u6587\u4ef6\u5939\u8def\u5f84<\/td>\n<\/tr>\n<tr>\n<td>FileNames<\/td>\n<td>ICollection<\/td>\n<td>\u591a\u9009\u65f6\u7684\u6240\u6709\u6587\u4ef6\u8def\u5f84\u96c6\u5408<\/td>\n<\/tr>\n<tr>\n<td>Filters<\/td>\n<td>IList<\/td>\n<td>\u6587\u4ef6\u7c7b\u578b\u8fc7\u6ee4\u5668<\/td>\n<\/tr>\n<tr>\n<td>EnsurePathExists<\/td>\n<td>bool<\/td>\n<td>\u786e\u4fdd\u8def\u5f84\u5b58\u5728<\/td>\n<\/tr>\n<tr>\n<td>EnsureValidNames<\/td>\n<td>bool<\/td>\n<td>\u786e\u4fdd\u6587\u4ef6\u540d\u6709\u6548<\/td>\n<\/tr>\n<tr>\n<td>EnsureReadOnly<\/td>\n<td>bool<\/td>\n<td>\u786e\u4fdd\u6587\u4ef6\u4e3a\u53ea\u8bfb<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3>\u5e38\u7528\u65b9\u6cd5<\/h3>\n<ul>\n<li>ShowDialog()<br \/>\n\u663e\u793a\u5bf9\u8bdd\u6846&#xff0c;\u8fd4\u56deCommonFileDialogResult\u679a\u4e3e<\/li>\n<li>ShowDialog(Window owner)<br \/>\n\u6307\u5b9a\u6240\u6709\u8005\u7a97\u53e3\u663e\u793a<br \/>\n##CommonFileDialogResult \u679a\u4e3e\u503c<\/li>\n<li>Ok&#xff1a;\u7528\u6237\u70b9\u51fb\u786e\u5b9a<\/li>\n<li>Cancel&#xff1a;\u7528\u6237\u53d6\u6d88<\/li>\n<\/ul>\n<h2>\u56db\u3001\u7a0b\u5e8f<\/h2>\n<h3>1\u3001MainWindow.xaml<\/h3>\n<p>&lt;Window x:Class&#061;&#034;WpfA_OpenFileFolderDemo.MainWindow&#034;<br \/>\n        xmlns&#061;&#034;http:\/\/schemas.microsoft.com\/winfx\/2006\/xaml\/presentation&#034;<br \/>\n        xmlns:x&#061;&#034;http:\/\/schemas.microsoft.com\/winfx\/2006\/xaml&#034;<br \/>\n        xmlns:d&#061;&#034;http:\/\/schemas.microsoft.com\/expression\/blend\/2008&#034;<br \/>\n        xmlns:mc&#061;&#034;http:\/\/schemas.openxmlformats.org\/markup-compatibility\/2006&#034;<br \/>\n        xmlns:local&#061;&#034;clr-namespace:WpfA_OpenFileFolderDemo&#034;<br \/>\n        Title&#061;&#034;\u6587\u4ef6\/\u6587\u4ef6\u5939\u9009\u62e9\u5bf9\u8bdd\u6846\u6f14\u793a &#8211; .NET Framework 4.8&#034;<br \/>\n        Height&#061;&#034;550&#034;<br \/>\n        Width&#061;&#034;750&#034;<br \/>\n        WindowStartupLocation&#061;&#034;CenterScreen&#034;<br \/>\n        Background&#061;&#034;#F5F5F5&#034;&gt;<\/p>\n<p>    &lt;Window.Resources&gt;<br \/>\n        &lt;!&#8211; TextBox\u5706\u89d2\u6837\u5f0f &#8211;&gt;<br \/>\n        &lt;Style TargetType&#061;&#034;TextBox&#034; x:Key&#061;&#034;RoundedTextBox&#034;&gt;<br \/>\n            &lt;Setter Property&#061;&#034;Template&#034;&gt;<br \/>\n                &lt;Setter.Value&gt;<br \/>\n                    &lt;ControlTemplate TargetType&#061;&#034;TextBox&#034;&gt;<br \/>\n                        &lt;Border Background&#061;&#034;{TemplateBinding Background}&#034;<br \/>\n                                BorderBrush&#061;&#034;{TemplateBinding BorderBrush}&#034;<br \/>\n                                BorderThickness&#061;&#034;{TemplateBinding BorderThickness}&#034;<br \/>\n                                CornerRadius&#061;&#034;4&#034;&gt;<br \/>\n                            &lt;ScrollViewer x:Name&#061;&#034;PART_ContentHost&#034;<br \/>\n                                          Margin&#061;&#034;5,2&#034;<br \/>\n                                          VerticalScrollBarVisibility&#061;&#034;Auto&#034;\/&gt;<br \/>\n                        &lt;\/Border&gt;<br \/>\n                    &lt;\/ControlTemplate&gt;<br \/>\n                &lt;\/Setter.Value&gt;<br \/>\n            &lt;\/Setter&gt;<br \/>\n        &lt;\/Style&gt;<\/p>\n<p>        &lt;Style TargetType&#061;&#034;Button&#034; x:Key&#061;&#034;DemoButton&#034;&gt;<br \/>\n            &lt;Setter Property&#061;&#034;Width&#034; Value&#061;&#034;380&#034;\/&gt;<br \/>\n            &lt;Setter Property&#061;&#034;Height&#034; Value&#061;&#034;48&#034;\/&gt;<br \/>\n            &lt;Setter Property&#061;&#034;Margin&#034; Value&#061;&#034;0,6&#034;\/&gt;<br \/>\n            &lt;Setter Property&#061;&#034;FontSize&#034; Value&#061;&#034;15&#034;\/&gt;<br \/>\n            &lt;Setter Property&#061;&#034;Cursor&#034; Value&#061;&#034;Hand&#034;\/&gt;<br \/>\n            &lt;Setter Property&#061;&#034;Background&#034; Value&#061;&#034;#3498DB&#034;\/&gt;<br \/>\n            &lt;Setter Property&#061;&#034;Foreground&#034; Value&#061;&#034;White&#034;\/&gt;<br \/>\n            &lt;Setter Property&#061;&#034;BorderThickness&#034; Value&#061;&#034;0&#034;\/&gt;<br \/>\n            &lt;Setter Property&#061;&#034;Template&#034;&gt;<br \/>\n                &lt;Setter.Value&gt;<br \/>\n                    &lt;ControlTemplate TargetType&#061;&#034;Button&#034;&gt;<br \/>\n                        &lt;Border Background&#061;&#034;{TemplateBinding Background}&#034;<br \/>\n                                CornerRadius&#061;&#034;6&#034;<br \/>\n                                BorderThickness&#061;&#034;0&#034;&gt;<br \/>\n                            &lt;ContentPresenter HorizontalAlignment&#061;&#034;Center&#034;<br \/>\n                                              VerticalAlignment&#061;&#034;Center&#034;<br \/>\n                                              Margin&#061;&#034;10,0&#034;\/&gt;<br \/>\n                        &lt;\/Border&gt;<br \/>\n                        &lt;ControlTemplate.Triggers&gt;<br \/>\n                            &lt;Trigger Property&#061;&#034;IsMouseOver&#034; Value&#061;&#034;True&#034;&gt;<br \/>\n                                &lt;Setter Property&#061;&#034;Background&#034; Value&#061;&#034;#2980B9&#034;\/&gt;<br \/>\n                            &lt;\/Trigger&gt;<br \/>\n                            &lt;Trigger Property&#061;&#034;IsPressed&#034; Value&#061;&#034;True&#034;&gt;<br \/>\n                                &lt;Setter Property&#061;&#034;Background&#034; Value&#061;&#034;#1A5276&#034;\/&gt;<br \/>\n                            &lt;\/Trigger&gt;<br \/>\n                        &lt;\/ControlTemplate.Triggers&gt;<br \/>\n                    &lt;\/ControlTemplate&gt;<br \/>\n                &lt;\/Setter.Value&gt;<br \/>\n            &lt;\/Setter&gt;<br \/>\n        &lt;\/Style&gt;<\/p>\n<p>        &lt;Style TargetType&#061;&#034;Button&#034; x:Key&#061;&#034;ClearButton&#034;&gt;<br \/>\n            &lt;Setter Property&#061;&#034;Width&#034; Value&#061;&#034;120&#034;\/&gt;<br \/>\n            &lt;Setter Property&#061;&#034;Height&#034; Value&#061;&#034;30&#034;\/&gt;<br \/>\n            &lt;Setter Property&#061;&#034;FontSize&#034; Value&#061;&#034;13&#034;\/&gt;<br \/>\n            &lt;Setter Property&#061;&#034;Background&#034; Value&#061;&#034;#E74C3C&#034;\/&gt;<br \/>\n            &lt;Setter Property&#061;&#034;Foreground&#034; Value&#061;&#034;White&#034;\/&gt;<br \/>\n            &lt;Setter Property&#061;&#034;BorderThickness&#034; Value&#061;&#034;0&#034;\/&gt;<br \/>\n            &lt;Setter Property&#061;&#034;Cursor&#034; Value&#061;&#034;Hand&#034;\/&gt;<br \/>\n            &lt;Setter Property&#061;&#034;Template&#034;&gt;<br \/>\n                &lt;Setter.Value&gt;<br \/>\n                    &lt;ControlTemplate TargetType&#061;&#034;Button&#034;&gt;<br \/>\n                        &lt;Border Background&#061;&#034;{TemplateBinding Background}&#034;<br \/>\n                                CornerRadius&#061;&#034;4&#034;&gt;<br \/>\n                            &lt;ContentPresenter HorizontalAlignment&#061;&#034;Center&#034;<br \/>\n                                              VerticalAlignment&#061;&#034;Center&#034;\/&gt;<br \/>\n                        &lt;\/Border&gt;<br \/>\n                        &lt;ControlTemplate.Triggers&gt;<br \/>\n                            &lt;Trigger Property&#061;&#034;IsMouseOver&#034; Value&#061;&#034;True&#034;&gt;<br \/>\n                                &lt;Setter Property&#061;&#034;Background&#034; Value&#061;&#034;#C0392B&#034;\/&gt;<br \/>\n                            &lt;\/Trigger&gt;<br \/>\n                            &lt;Trigger Property&#061;&#034;IsPressed&#034; Value&#061;&#034;True&#034;&gt;<br \/>\n                                &lt;Setter Property&#061;&#034;Background&#034; Value&#061;&#034;#922B21&#034;\/&gt;<br \/>\n                            &lt;\/Trigger&gt;<br \/>\n                        &lt;\/ControlTemplate.Triggers&gt;<br \/>\n                    &lt;\/ControlTemplate&gt;<br \/>\n                &lt;\/Setter.Value&gt;<br \/>\n            &lt;\/Setter&gt;<br \/>\n        &lt;\/Style&gt;<br \/>\n    &lt;\/Window.Resources&gt;<\/p>\n<p>    &lt;Grid Margin&#061;&#034;20&#034;&gt;<br \/>\n        &lt;Grid.RowDefinitions&gt;<br \/>\n            &lt;RowDefinition Height&#061;&#034;Auto&#034;\/&gt;<br \/>\n            &lt;RowDefinition Height&#061;&#034;Auto&#034;\/&gt;<br \/>\n            &lt;RowDefinition Height&#061;&#034;*&#034;\/&gt;<br \/>\n        &lt;\/Grid.RowDefinitions&gt;<\/p>\n<p>        &lt;Border Grid.Row&#061;&#034;0&#034; Background&#061;&#034;#2C3E50&#034; CornerRadius&#061;&#034;8&#034; Padding&#061;&#034;15&#034; Margin&#061;&#034;0,0,0,20&#034;&gt;<br \/>\n            &lt;TextBlock Text&#061;&#034;&#x1f4c1; \u6587\u4ef6\u4e0e\u6587\u4ef6\u5939\u9009\u62e9\u5bf9\u8bdd\u6846\u6f14\u793a&#034;<br \/>\n                       FontSize&#061;&#034;22&#034;<br \/>\n                       FontWeight&#061;&#034;Bold&#034;<br \/>\n                       Foreground&#061;&#034;White&#034;<br \/>\n                       HorizontalAlignment&#061;&#034;Center&#034;\/&gt;<br \/>\n        &lt;\/Border&gt;<\/p>\n<p>        &lt;StackPanel Grid.Row&#061;&#034;1&#034; Orientation&#061;&#034;Vertical&#034; HorizontalAlignment&#061;&#034;Center&#034;&gt;<br \/>\n            &lt;Button Style&#061;&#034;{StaticResource DemoButton}&#034;<br \/>\n                    Content&#061;&#034;&#x1f4c2; \u6253\u5f00\u6587\u4ef6 (OpenFileDialog)&#034;<br \/>\n                    Click&#061;&#034;OpenFile_Click&#034;<br \/>\n                    ToolTip&#061;&#034;\u4f7f\u7528Win32\u6807\u51c6\u5bf9\u8bdd\u6846\u9009\u62e9\u56fe\u7247\u6587\u4ef6&#034;\/&gt;<\/p>\n<p>            &lt;Button Style&#061;&#034;{StaticResource DemoButton}&#034;<br \/>\n                    Content&#061;&#034;&#x1f4be; \u4fdd\u5b58\u6587\u4ef6 (SaveFileDialog)&#034;<br \/>\n                    Click&#061;&#034;SaveFile_Click&#034;<br \/>\n                    ToolTip&#061;&#034;\u4f7f\u7528Win32\u6807\u51c6\u5bf9\u8bdd\u6846\u4fdd\u5b58BMP\u56fe\u50cf&#034;\/&gt;<\/p>\n<p>            &lt;Button Style&#061;&#034;{StaticResource DemoButton}&#034;<br \/>\n                    Content&#061;&#034;&#x1f4c1; \u6253\u5f00\u6587\u4ef6\u5939 (FolderBrowserDialog)&#034;<br \/>\n                    Click&#061;&#034;FolderBrowser_Click&#034;<br \/>\n                    ToolTip&#061;&#034;\u4f7f\u7528WinForms\u7ec4\u4ef6\u9009\u62e9\u6587\u4ef6\u5939 (\u4f20\u7edf\u6837\u5f0f)&#034;\/&gt;<\/p>\n<p>            &lt;Button Style&#061;&#034;{StaticResource DemoButton}&#034;<br \/>\n                    Content&#061;&#034;&#x1f4c1; \u6253\u5f00\u6587\u4ef6\u5939 (CommonOpenFileDialog)&#034;<br \/>\n                    Click&#061;&#034;CommonOpenFile_Click&#034;<br \/>\n                    ToolTip&#061;&#034;\u4f7f\u7528Windows API Code Pack\u9009\u62e9\u6587\u4ef6\u5939 (Vista\u98ce\u683c)&#034;\/&gt;<\/p>\n<p>            &lt;Button Style&#061;&#034;{StaticResource ClearButton}&#034;<br \/>\n                    Content&#061;&#034;&#x1f5d1;\ufe0f \u6e05\u7a7a\u7ed3\u679c&#034;<br \/>\n                    Margin&#061;&#034;0,15,0,0&#034;<br \/>\n                    Click&#061;&#034;ClearResult_Click&#034;\/&gt;<br \/>\n        &lt;\/StackPanel&gt;<\/p>\n<p>        &lt;Border Grid.Row&#061;&#034;2&#034;<br \/>\n                Margin&#061;&#034;0,20,0,0&#034;<br \/>\n                Padding&#061;&#034;15&#034;<br \/>\n                Background&#061;&#034;White&#034;<br \/>\n                BorderBrush&#061;&#034;#BDC3C7&#034;<br \/>\n                BorderThickness&#061;&#034;1&#034;<br \/>\n                CornerRadius&#061;&#034;8&#034;<br \/>\n                Height&#061;&#034;150&#034;&gt;<br \/>\n            &lt;Grid&gt;<br \/>\n                &lt;Grid.RowDefinitions&gt;<br \/>\n                    &lt;RowDefinition Height&#061;&#034;Auto&#034;\/&gt;<br \/>\n                    &lt;RowDefinition Height&#061;&#034;*&#034;\/&gt;<br \/>\n                &lt;\/Grid.RowDefinitions&gt;<\/p>\n<p>                &lt;TextBlock Grid.Row&#061;&#034;0&#034;<br \/>\n                           Text&#061;&#034;&#x1f4cb; \u9009\u62e9\u7ed3\u679c&#xff1a;&#034;<br \/>\n                           FontWeight&#061;&#034;Bold&#034;<br \/>\n                           FontSize&#061;&#034;14&#034;<br \/>\n                           Margin&#061;&#034;0,0,0,8&#034;<br \/>\n                           Foreground&#061;&#034;#2C3E50&#034;\/&gt;<\/p>\n<p>                &lt;TextBox Grid.Row&#061;&#034;1&#034;<br \/>\n                         x:Name&#061;&#034;ResultTextBox&#034;<br \/>\n                         Style&#061;&#034;{StaticResource RoundedTextBox}&#034;<br \/>\n                         TextWrapping&#061;&#034;Wrap&#034;<br \/>\n                         AcceptsReturn&#061;&#034;True&#034;<br \/>\n                         VerticalScrollBarVisibility&#061;&#034;Auto&#034;<br \/>\n                         IsReadOnly&#061;&#034;True&#034;<br \/>\n                         Background&#061;&#034;#FAFAFA&#034;<br \/>\n                         BorderBrush&#061;&#034;#D5D8DC&#034;<br \/>\n                         BorderThickness&#061;&#034;1&#034;<br \/>\n                         FontFamily&#061;&#034;Consolas&#034;<br \/>\n                         FontSize&#061;&#034;13&#034;<br \/>\n                         Padding&#061;&#034;8&#034;\/&gt;<br \/>\n            &lt;\/Grid&gt;<br \/>\n        &lt;\/Border&gt;<\/p>\n<p>        &lt;StatusBar Grid.Row&#061;&#034;2&#034;<br \/>\n                   VerticalAlignment&#061;&#034;Bottom&#034;<br \/>\n                   Height&#061;&#034;25&#034;<br \/>\n                   Background&#061;&#034;#ECF0F1&#034;&gt;<br \/>\n            &lt;StatusBarItem&gt;<br \/>\n                &lt;TextBlock x:Name&#061;&#034;StatusText&#034;<br \/>\n                           Text&#061;&#034;\u5c31\u7eea&#034;<br \/>\n                           FontSize&#061;&#034;12&#034;<br \/>\n                           Foreground&#061;&#034;#7F8C8D&#034;\/&gt;<br \/>\n            &lt;\/StatusBarItem&gt;<br \/>\n        &lt;\/StatusBar&gt;<br \/>\n    &lt;\/Grid&gt;<br \/>\n&lt;\/Window&gt;<\/p>\n<h3>2\u3001MainWindow.xaml.cs<\/h3>\n<p>using System;<br \/>\nusing System.Windows;<br \/>\nusing Microsoft.Win32;<br \/>\nusing Microsoft.WindowsAPICodePack.Dialogs;<\/p>\n<p>namespace WpfA_OpenFileFolderDemo<br \/>\n{<br \/>\n    public partial class MainWindow : Window<br \/>\n    {<br \/>\n        public MainWindow()<br \/>\n        {<br \/>\n            InitializeComponent();<br \/>\n        }<\/p>\n<p>        \/\/\/ &lt;summary&gt;<br \/>\n        \/\/\/ \u66f4\u65b0\u7ed3\u679c\u6587\u672c\u6846\u548c\u72b6\u6001\u680f<br \/>\n        \/\/\/ &lt;\/summary&gt;<br \/>\n        private void UpdateResult(string message, bool isSuccess &#061; true)<br \/>\n        {<br \/>\n            string timestamp &#061; DateTime.Now.ToString(&#034;HH:mm:ss&#034;);<br \/>\n            string icon &#061; isSuccess ? &#034;\u2705&#034; : &#034;\u274c&#034;;<\/p>\n<p>            \/\/ \u5728\u7ed3\u679c\u6846\u4e2d\u8ffd\u52a0\u5185\u5bb9<br \/>\n            string newLine &#061; $&#034;[{timestamp}] {message}&#034;;<br \/>\n            if (string.IsNullOrEmpty(ResultTextBox.Text))<br \/>\n            {<br \/>\n                ResultTextBox.Text &#061; newLine;<br \/>\n            }<br \/>\n            else<br \/>\n            {<br \/>\n                ResultTextBox.Text &#043;&#061; Environment.NewLine &#043; newLine;<br \/>\n            }<\/p>\n<p>            \/\/ \u6eda\u52a8\u5230\u5e95\u90e8<br \/>\n            ResultTextBox.ScrollToEnd();<\/p>\n<p>            \/\/ \u66f4\u65b0\u72b6\u6001\u680f<br \/>\n            StatusText.Text &#061; isSuccess ? $&#034;\u2713 {message}&#034; : $&#034;\u2717 {message}&#034;;<br \/>\n            StatusText.Foreground &#061; isSuccess ?<br \/>\n                System.Windows.Media.Brushes.Green :<br \/>\n                System.Windows.Media.Brushes.Red;<br \/>\n        }<\/p>\n<p>        \/\/\/ &lt;summary&gt;<br \/>\n        \/\/\/ \u6e05\u7a7a\u7ed3\u679c<br \/>\n        \/\/\/ &lt;\/summary&gt;<br \/>\n        private void ClearResult_Click(object sender, RoutedEventArgs e)<br \/>\n        {<br \/>\n            ResultTextBox.Clear();<br \/>\n            StatusText.Text &#061; &#034;\u5df2\u6e05\u7a7a&#034;;<br \/>\n            StatusText.Foreground &#061; System.Windows.Media.Brushes.Gray;<br \/>\n        }<\/p>\n<p>        \/\/\/ &lt;summary&gt;<br \/>\n        \/\/\/ \u6253\u5f00\u6587\u4ef6 &#8211; OpenFileDialog<br \/>\n        \/\/\/ &lt;\/summary&gt;<br \/>\n        private void OpenFile_Click(object sender, RoutedEventArgs e)<br \/>\n        {<br \/>\n            try<br \/>\n            {<br \/>\n                OpenFileDialog dialog &#061; new OpenFileDialog<br \/>\n                {<br \/>\n                    Title &#061; &#034;\u9009\u62e9\u56fe\u7247\u6587\u4ef6&#034;,<br \/>\n                    Filter &#061; &#034;\u56fe\u50cf\u6587\u4ef6 (*.jpg;*.png;*.bmp;*.gif)|*.jpg;*.png;*.bmp;*.gif|\u6240\u6709\u6587\u4ef6 (*.*)|*.*&#034;,<br \/>\n                    RestoreDirectory &#061; true,<br \/>\n                    Multiselect &#061; false,<br \/>\n                    InitialDirectory &#061; Environment.GetFolderPath(Environment.SpecialFolder.MyPictures)<br \/>\n                };<\/p>\n<p>                bool? result &#061; dialog.ShowDialog();<br \/>\n                if (result &#061;&#061; true)<br \/>\n                {<br \/>\n                    UpdateResult($&#034;\u9009\u62e9\u4e86\u6587\u4ef6&#xff1a;{dialog.FileName}&#034;, true);<br \/>\n                }<br \/>\n                else<br \/>\n                {<br \/>\n                    UpdateResult(&#034;\u7528\u6237\u53d6\u6d88\u4e86\u64cd\u4f5c&#034;, true);<br \/>\n                }<br \/>\n            }<br \/>\n            catch (Exception ex)<br \/>\n            {<br \/>\n                UpdateResult($&#034;\u9519\u8bef&#xff1a;{ex.Message}&#034;, false);<br \/>\n            }<br \/>\n        }<\/p>\n<p>        \/\/\/ &lt;summary&gt;<br \/>\n        \/\/\/ \u4fdd\u5b58\u6587\u4ef6 &#8211; SaveFileDialog<br \/>\n        \/\/\/ &lt;\/summary&gt;<br \/>\n        private void SaveFile_Click(object sender, RoutedEventArgs e)<br \/>\n        {<br \/>\n            try<br \/>\n            {<br \/>\n                SaveFileDialog dialog &#061; new SaveFileDialog<br \/>\n                {<br \/>\n                    Title &#061; &#034;\u4fdd\u5b58\u56fe\u50cf\u6587\u4ef6&#034;,<br \/>\n                    Filter &#061; &#034;BMP\u56fe\u50cf (*.bmp)|*.bmp|PNG\u56fe\u50cf (*.png)|*.png|JPEG\u56fe\u50cf (*.jpg)|*.jpg&#034;,<br \/>\n                    RestoreDirectory &#061; true,<br \/>\n                    FileName &#061; $&#034;Image_{DateTime.Now:yyyyMMdd_HHmmss}.bmp&#034;,<br \/>\n                    DefaultExt &#061; &#034;.bmp&#034;,<br \/>\n                    AddExtension &#061; true,<br \/>\n                    InitialDirectory &#061; Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments)<br \/>\n                };<\/p>\n<p>                bool? result &#061; dialog.ShowDialog();<br \/>\n                if (result &#061;&#061; true)<br \/>\n                {<br \/>\n                    UpdateResult($&#034;\u4fdd\u5b58\u8def\u5f84&#xff1a;{dialog.FileName}&#034;, true);<br \/>\n                }<br \/>\n                else<br \/>\n                {<br \/>\n                    UpdateResult(&#034;\u7528\u6237\u53d6\u6d88\u4e86\u64cd\u4f5c&#034;, true);<br \/>\n                }<br \/>\n            }<br \/>\n            catch (Exception ex)<br \/>\n            {<br \/>\n                UpdateResult($&#034;\u9519\u8bef&#xff1a;{ex.Message}&#034;, false);<br \/>\n            }<br \/>\n        }<\/p>\n<p>        \/\/\/ &lt;summary&gt;<br \/>\n        \/\/\/ \u6253\u5f00\u6587\u4ef6\u5939 &#8211; FolderBrowserDialog (WinForms)<br \/>\n        \/\/\/ &lt;\/summary&gt;<br \/>\n        private void FolderBrowser_Click(object sender, RoutedEventArgs e)<br \/>\n        {<br \/>\n            try<br \/>\n            {<br \/>\n                System.Windows.Forms.FolderBrowserDialog dialog &#061;<br \/>\n                    new System.Windows.Forms.FolderBrowserDialog<br \/>\n                    {<br \/>\n                        Description &#061; &#034;\u8bf7\u9009\u62e9\u76ee\u6807\u6587\u4ef6\u5939&#034;,<br \/>\n                        ShowNewFolderButton &#061; true,<br \/>\n                        RootFolder &#061; Environment.SpecialFolder.Desktop<br \/>\n                    };<\/p>\n<p>                \/\/ \u4f7f\u7528WinForms\u7684\u5bf9\u8bdd\u6846<br \/>\n                System.Windows.Forms.DialogResult result &#061; dialog.ShowDialog();<br \/>\n                if (result &#061;&#061; System.Windows.Forms.DialogResult.OK)<br \/>\n                {<br \/>\n                    string foldername &#061; dialog.SelectedPath.Trim();<br \/>\n                    UpdateResult($&#034;\u9009\u62e9\u4e86\u6587\u4ef6\u5939&#xff1a;{foldername}&#034;, true);<br \/>\n                }<br \/>\n                else<br \/>\n                {<br \/>\n                    UpdateResult(&#034;\u7528\u6237\u53d6\u6d88\u4e86\u64cd\u4f5c&#034;, true);<br \/>\n                }<br \/>\n            }<br \/>\n            catch (Exception ex)<br \/>\n            {<br \/>\n                UpdateResult($&#034;\u9519\u8bef&#xff1a;{ex.Message}&#034;, false);<br \/>\n            }<br \/>\n        }<\/p>\n<p>        \/\/\/ &lt;summary&gt;<br \/>\n        \/\/\/ \u6253\u5f00\u6587\u4ef6\u5939 &#8211; CommonOpenFileDialog (Windows API Code Pack)<br \/>\n        \/\/\/ &lt;\/summary&gt;<br \/>\n        private void CommonOpenFile_Click(object sender, RoutedEventArgs e)<br \/>\n        {<br \/>\n            try<br \/>\n            {<br \/>\n                \/\/ \u68c0\u67e5\u64cd\u4f5c\u7cfb\u7edf\u7248\u672c&#xff08;Vista&#043;&#xff09;<br \/>\n                if (Environment.OSVersion.Version.Major &lt; 6)<br \/>\n                {<br \/>\n                    UpdateResult(&#034;\u9700\u8981 Windows Vista \u6216\u66f4\u9ad8\u7248\u672c\u624d\u80fd\u4f7f\u7528\u6b64\u529f\u80fd&#034;, false);<br \/>\n                    return;<br \/>\n                }<\/p>\n<p>                using (CommonOpenFileDialog dialog &#061; new CommonOpenFileDialog())<br \/>\n                {<br \/>\n                    dialog.Title &#061; &#034;\u8bf7\u9009\u62e9\u76ee\u6807\u6587\u4ef6\u5939 (Vista&#043; \u98ce\u683c)&#034;;<br \/>\n                    dialog.IsFolderPicker &#061; true;<br \/>\n                    dialog.Multiselect &#061; false;<br \/>\n                    dialog.EnsurePathExists &#061; true;<br \/>\n                    dialog.EnsureValidNames &#061; true;<br \/>\n                    dialog.InitialDirectory &#061; Environment.GetFolderPath(<br \/>\n                        Environment.SpecialFolder.Desktop<br \/>\n                    );<\/p>\n<p>                    \/\/ \u663e\u793a\u5bf9\u8bdd\u6846<br \/>\n                    CommonFileDialogResult result &#061; dialog.ShowDialog();<br \/>\n                    if (result &#061;&#061; CommonFileDialogResult.Ok)<br \/>\n                    {<br \/>\n                        string folderName &#061; dialog.FileName;<br \/>\n                        UpdateResult($&#034;\u9009\u62e9\u4e86\u6587\u4ef6\u5939&#xff1a;{folderName}&#034;, true);<br \/>\n                    }<br \/>\n                    else<br \/>\n                    {<br \/>\n                        UpdateResult(&#034;\u7528\u6237\u53d6\u6d88\u4e86\u64cd\u4f5c&#034;, true);<br \/>\n                    }<br \/>\n                }<br \/>\n            }<br \/>\n            catch (Exception ex)<br \/>\n            {<br \/>\n                UpdateResult($&#034;\u9519\u8bef&#xff1a;{ex.Message}&#034;, false);<br \/>\n            }<br \/>\n        }<br \/>\n    }<br \/>\n}<\/p>\n<h2>\u4e94\u3001\u8d44\u6599<\/h2>\n<p>\u30101.8 HandyControl&#xff1a;80\u4f59\u79cd\u63a7\u4ef6\u4f7f\u7528\u6848\u4f8b\u3011WPF\u6848\u4f8b\u4ee3\u7801\u89e3\u6790 &#8211; \u77e5\u4e4e](https:\/\/zhuanlan.zhihu.com\/p\/393756032)<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u73af\u5883&#xff1a;  VS2022.Net Framework4.8<br \/>\nNuGet\u5305&#xff1a;WindowsAPICodePack-Core 1.1.2  &#xff1b;<br \/>\nWindowsAPICodePack-Shell 1.1.1<br \/>\n\u7a0b\u5e8f\u540d&#xff1a;WpfA_OpenFileFolderDemo<br \/>\n\u4e00\u3001\u529f\u80fd\u6982\u8ff0<br \/>\n\u8fd9\u662f\u4e00\u4e2aWPF\u7528\u6237\u63a7\u4ef6&#xff0c;\u6f14\u793a\u4e86\u56db\u79cd\u4e0d\u540c\u7684\u6587\u4ef6\u548c\u6587\u4ef6\u5939\u9009\u62e9\u5bf9\u8bdd\u6846&#xff1a;<br \/>\n\u6253\u5f00\u6587\u4ef6\u5bf9\u8bdd\u6846&#xff08;OpenFileDialog&amp;<\/p>\n","protected":false},"author":2,"featured_media":102050,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[55,1862],"topic":[],"class_list":["post-102051","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-server","tag-c","tag-wpf"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>WPF\uff1a\u6587\u4ef6\/\u6587\u4ef6\u5939\u9009\u62e9\u5bf9\u8bdd\u6846 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.wsisp.com\/helps\/102051.html\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"WPF\uff1a\u6587\u4ef6\/\u6587\u4ef6\u5939\u9009\u62e9\u5bf9\u8bdd\u6846 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"og:description\" content=\"\u73af\u5883&#xff1a; VS2022.Net Framework4.8 NuGet\u5305&#xff1a;WindowsAPICodePack-Core 1.1.2 &#xff1b; WindowsAPICodePack-Shell 1.1.1 \u7a0b\u5e8f\u540d&#xff1a;WpfA_OpenFileFolderDemo \u4e00\u3001\u529f\u80fd\u6982\u8ff0 \u8fd9\u662f\u4e00\u4e2aWPF\u7528\u6237\u63a7\u4ef6&#xff0c;\u6f14\u793a\u4e86\u56db\u79cd\u4e0d\u540c\u7684\u6587\u4ef6\u548c\u6587\u4ef6\u5939\u9009\u62e9\u5bf9\u8bdd\u6846&#xff1a; \u6253\u5f00\u6587\u4ef6\u5bf9\u8bdd\u6846&#xff08;OpenFileDialog&amp;\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wsisp.com\/helps\/102051.html\" \/>\n<meta property=\"og:site_name\" content=\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"article:published_time\" content=\"2026-09-07T19:43:18+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260907194317-6a9f13d581605.png\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"6 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/102051.html\",\"url\":\"https:\/\/www.wsisp.com\/helps\/102051.html\",\"name\":\"WPF\uff1a\u6587\u4ef6\/\u6587\u4ef6\u5939\u9009\u62e9\u5bf9\u8bdd\u6846 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"isPartOf\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\"},\"datePublished\":\"2026-09-07T19:43:18+00:00\",\"dateModified\":\"2026-09-07T19:43:18+00:00\",\"author\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/102051.html#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.wsisp.com\/helps\/102051.html\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/102051.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wsisp.com\/helps\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"WPF\uff1a\u6587\u4ef6\/\u6587\u4ef6\u5939\u9009\u62e9\u5bf9\u8bdd\u6846\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\",\"url\":\"https:\/\/www.wsisp.com\/helps\/\",\"name\":\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"description\":\"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"contentUrl\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"caption\":\"admin\"},\"sameAs\":[\"http:\/\/wp.wsisp.com\"],\"url\":\"https:\/\/www.wsisp.com\/helps\/author\/admin\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"WPF\uff1a\u6587\u4ef6\/\u6587\u4ef6\u5939\u9009\u62e9\u5bf9\u8bdd\u6846 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.wsisp.com\/helps\/102051.html","og_locale":"zh_CN","og_type":"article","og_title":"WPF\uff1a\u6587\u4ef6\/\u6587\u4ef6\u5939\u9009\u62e9\u5bf9\u8bdd\u6846 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","og_description":"\u73af\u5883&#xff1a; VS2022.Net Framework4.8 NuGet\u5305&#xff1a;WindowsAPICodePack-Core 1.1.2 &#xff1b; WindowsAPICodePack-Shell 1.1.1 \u7a0b\u5e8f\u540d&#xff1a;WpfA_OpenFileFolderDemo \u4e00\u3001\u529f\u80fd\u6982\u8ff0 \u8fd9\u662f\u4e00\u4e2aWPF\u7528\u6237\u63a7\u4ef6&#xff0c;\u6f14\u793a\u4e86\u56db\u79cd\u4e0d\u540c\u7684\u6587\u4ef6\u548c\u6587\u4ef6\u5939\u9009\u62e9\u5bf9\u8bdd\u6846&#xff1a; \u6253\u5f00\u6587\u4ef6\u5bf9\u8bdd\u6846&#xff08;OpenFileDialog&amp;","og_url":"https:\/\/www.wsisp.com\/helps\/102051.html","og_site_name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","article_published_time":"2026-09-07T19:43:18+00:00","og_image":[{"url":"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2026\/09\/20260907194317-6a9f13d581605.png"}],"author":"admin","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"admin","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"6 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.wsisp.com\/helps\/102051.html","url":"https:\/\/www.wsisp.com\/helps\/102051.html","name":"WPF\uff1a\u6587\u4ef6\/\u6587\u4ef6\u5939\u9009\u62e9\u5bf9\u8bdd\u6846 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","isPartOf":{"@id":"https:\/\/www.wsisp.com\/helps\/#website"},"datePublished":"2026-09-07T19:43:18+00:00","dateModified":"2026-09-07T19:43:18+00:00","author":{"@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41"},"breadcrumb":{"@id":"https:\/\/www.wsisp.com\/helps\/102051.html#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wsisp.com\/helps\/102051.html"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.wsisp.com\/helps\/102051.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wsisp.com\/helps"},{"@type":"ListItem","position":2,"name":"WPF\uff1a\u6587\u4ef6\/\u6587\u4ef6\u5939\u9009\u62e9\u5bf9\u8bdd\u6846"}]},{"@type":"WebSite","@id":"https:\/\/www.wsisp.com\/helps\/#website","url":"https:\/\/www.wsisp.com\/helps\/","name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","description":"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"zh-Hans"},{"@type":"Person","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41","name":"admin","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/","url":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","contentUrl":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","caption":"admin"},"sameAs":["http:\/\/wp.wsisp.com"],"url":"https:\/\/www.wsisp.com\/helps\/author\/admin"}]}},"_links":{"self":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/102051","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/comments?post=102051"}],"version-history":[{"count":0,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/102051\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media\/102050"}],"wp:attachment":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media?parent=102051"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/categories?post=102051"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/tags?post=102051"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/topic?post=102051"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}