在.NET中将OpenFileDialog定制为只读 [英] customize OpenFileDialog as read only in .NET

查看:97
本文介绍了在.NET中将OpenFileDialog定制为只读的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在.NET中自定义OpenFileDialog为只读

How can i customize OpenFileDialog as read only in .NET

推荐答案

OpenFileDialog 仅为您提供文件名并且不打开文件,这是你的责任,但是你可以提供 ShowReadOnly 属性,请看这里:http://msdn.microsoft.com/en-us/library/system.windows.forms.openfiledialog.aspx [<一个href =http://msdn.microsoft.com/en-us/library/system.windows.forms.openfiledialog.aspxtarget =_ blanktitle =New Window> ^ ]



http:/ /msdn.microsoft.com/en-us/library/system.windows.forms.openfiledialog.showreadonly.aspx [ ^ ]
The OpenFileDialog only gives you a filename and does not open the file, that is your responsibility, however you can supply ShowReadOnly property, see here : http://msdn.microsoft.com/en-us/library/system.windows.forms.openfiledialog.aspx[^]

http://msdn.microsoft.com/en-us/library/system.windows.forms.openfiledialog.showreadonly.aspx[^]


这篇关于在.NET中将OpenFileDialog定制为只读的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆