HttpFileCollectionWrapper.Get 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
按名称或索引从集合中返回已发布的文件对象。
重载
| 名称 | 说明 |
|---|---|
| Get(Int32) |
返回指定索引处的已发布文件对象。 |
| Get(String) |
返回具有集合中指定名称的已发布文件对象。 |
Get(Int32)
返回指定索引处的已发布文件对象。
public:
override System::Web::HttpPostedFileBase ^ Get(int index);
public override System.Web.HttpPostedFileBase Get(int index);
override this.Get : int -> System.Web.HttpPostedFileBase
Public Overrides Function Get (index As Integer) As HttpPostedFileBase
参数
- index
- Int32
要返回的项的索引。
返回
由 index.. 指定的已发布文件对象。
例外
index 超出集合的有效索引范围。
适用于
Get(String)
返回具有集合中指定名称的已发布文件对象。
public:
override System::Web::HttpPostedFileBase ^ Get(System::String ^ name);
public override System.Web.HttpPostedFileBase Get(string name);
override this.Get : string -> System.Web.HttpPostedFileBase
Public Overrides Function Get (name As String) As HttpPostedFileBase
参数
- name
- String
要返回的对象的名称。
返回
找到后 name的文件对象(如果找到);否则为 null。