.NET中的`MessageBox`,`SaveFileDialog`:我应该使用哪个版本?(`MessageBox`, `SaveFileDialog` in .NET: which version

编程入门 行业动态 更新时间:2024-10-27 04:32:39
.NET中的`MessageBox`,`SaveFileDialog`:我应该使用哪个版本?(`MessageBox`, `SaveFileDialog` in .NET: which version should I use?)

我应该使用哪一个,有什么区别:

System.Windows.MessageBox

System.Windows.Forms.MessageBox

同样的问题关于System.Windows.Forms.SaveFileDialog和Microsoft.Win32.SaveFileDialog 。

我需要的只是显示一个消息框并保存文件对话框(也适用于Windows XP)。

适当的重新标记是赞赏。

在此先感谢,嗯。

Which one should I use and what are the differences:

System.Windows.MessageBox

System.Windows.Forms.MessageBox

The same question about System.Windows.Forms.SaveFileDialog and Microsoft.Win32.SaveFileDialog.

All I need is to show a message box and save file dialog (working on Windows XP as well).

Proper re-tagging is appreciated.

Thanks in advance, kh.

最满意答案

System.Windows.Forms名称空间中的控件适用于WinForms应用程序。 System.Windows命名空间中的控件适用于WPF / Silverlight应用程序。 所以选择与你的应用类型相匹配的控件。

The controls in the System.Windows.Forms namespace are for WinForms applications. The controls in the System.Windows namespace are for WPF/Silverlight applications. So pick the controls that match your application type.

更多推荐

本文发布于:2023-08-03 22:00:00,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1401101.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:版本   MessageBox   NET   version   SaveFileDialog

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!