如何在asp.net中上传文件 [英] How to upload Files in asp.net

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

问题描述

亲爱的专家,



我正在做一个asp.net项目。我需要使用文件上传控件来上传文件。但我没有得到上传的事件。手段,



当用户单击文件上传控件的浏览按钮时,文件浏览器将打开,然后用户选择文件并单击打开。然后我需要为此事件背后的代码..

我需要事件而不需要添加其他按钮进行上传...



有没有任何方式..



谢谢。



Dileep

Dear Experts,

I am Doing an asp.net project. I need to uplaod files using File upload control. But i didn't get the event for uploading. Means,

When the user Click the browse button of the File upload control , then the File Browser will open then the user select the file and click open. Then i need a code behind event for this..
I need the event without put other buttons for uplaoding...

Is there any way..

Thanks.

Dileep

推荐答案

请参阅 - 直接上传文件而不使用上传按钮 [ ^ ]。



这个线程已经准确地讨论了你需要什么。有许多公认的解决方案,请按照它们进行操作。
Refer - upload file directly without "upload" button[^].

This thread has discussed exactly what you need. There are many accepted solutions, so follow them.


尝试

使用ASP.NET上传文件 [ ^ ]

http://asp.net-tutorials.com/controls/file-upload-control/ [ ^ ]

http://www.tutorialspoint.com/asp.net/asp.net_file_uploading.htm [ ^ ]
Try
File Upload with ASP.NET[^]
http://asp.net-tutorials.com/controls/file-upload-control/[^]
http://www.tutorialspoint.com/asp.net/asp.net_file_uploading.htm[^]


参考



http://dotprogramming.blogspot.com/2013/07/how-to-use-fileupload-control-in-aspnet.html [ ^ ]



http://asp-net-example.blogspot.in/2008 /10/fileupload-control-example.html [ ^ ]


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

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