文件上传控件在asp.net中用作用户控件 [英] File upload control is use as user control in asp.net

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

问题描述

我创建了仅具有一个文件上载控件的用户控件..我在另一个用户控件中使用了该用户控件...但是我无法访问文件上载控件的方法(HashFile,PostFile).如何访问这些方法...


在此先感谢...

I create user control which have only one File upload control..I use that user control in another user control...but i cant access methods (HashFile,PostFile) of the File upload control..how can access the methods...


Thanks in advance...

推荐答案

您有一个用户控件(X),该用户控件具有文件上传功能,并且您在另一个名为(Y的用户控件中使用了该用户控件),简单地说,您需要公开需要在(X)用户控件中用作方法的文件上传方法(API),或者,如果您希望公开自己在用户控件中的文件上传控件(X ),选择所需的方法,而我更喜欢使用第一种方法,并为该用户控件提供某些功能.
You have a user control (X) which has a file upload, and you use that user control in another user control called (Y), well simply put you need to expose file upload methods (API''s) that you need to use as methods within (X) user control, or if you want you can expose the file upload control it self in user control (X), choose whatever method you want while I would prefer using the first one and expose certain functionality for that user control.


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

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