如何在asp.net中以progamatically方式创建文件对话框 [英] How to create a file dialog progamatically in asp.net

查看:78
本文介绍了如何在asp.net中以progamatically方式创建文件对话框的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述





在我的网页上我有文本框和按钮控件,当我点击按钮控件时我需要从我的硬盘(pc)和该文件中获取xml文件路径应该显示在文本框上。

怎么做而不是文件对话框。



问候,

Raghu。

Hi,

In my webpage i have textbox and button controls when i click button control i need to get xml file from my harddisk(pc) and that file path should be display on the textbox.
how to do this instead of file dialog.

Regards,
Raghu.

推荐答案

如果要读取位于服务器上的XML文件,则不需要文件对话框 - 更准确地说,文件上载控件。只需使用File类并读取XML。



如果您打算从客户端计算机读取XML文件,则必须将XML文件上载到服务器然后阅读...除了上传和上传控制之外别无选择
You don''t need the file dialog - more correctly, the File Upload Control if you want to read the XML file located on the server. Just use the File class and read the XML .

If you intend to read XML file from the client machine, then you will have to upload the XML file to the server and then read it...There is no alternative to uploading and upload control


这篇关于如何在asp.net中以progamatically方式创建文件对话框的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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