System.Web.HttpPostedFile.SaveAs Method

Saves the contents of an uploaded file.

Syntax

public void SaveAs (string filename)

Parameters

filename
The name of the saved file.

Remarks

The maximum size allowed for a request, which includes uploaded files, is 4 MB, by default. Maximum request size can be specified in the Machine.config or Web.config file in the maxRequestLength attribute of the httpRuntime Element (ASP.NET Settings Schema) element. The maximum request size for a specific page can be specified using the location Element (ASP.NET Settings Schema) element in a Web.config file.

Requirements

Namespace: System.Web
Assembly: System.Web (in System.Web.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0