# HttpPostedFile

Namespace: **Wisej.Core**

Assembly: **Wisej.Framework** (4.0.0.0)

Provides access to individual files that have been uploaded by a client.

{% tabs %}
{% tab title="C#" %}

```csharp
public class HttpPostedFile
```

{% endtab %}

{% tab title="VB.NET" %}

```visual-basic
Public Class HttpPostedFile
```

{% endtab %}
{% endtabs %}

## Properties

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) ContentLength

[Int64](https://docs.microsoft.com/dotnet/api/system.int64): Returns the size of an uploaded file, in bytes.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) ContentType

[String](https://docs.microsoft.com/dotnet/api/system.string): Returns the MIME content type of a file sent by a client.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) FileName

[String](https://docs.microsoft.com/dotnet/api/system.string): Return the fully qualified name of the file on the client.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) InputStream

[Stream](https://docs.microsoft.com/dotnet/api/system.io.stream): Returns a [Stream](https://docs.microsoft.com/dotnet/api/system.io.stream) object that points to an uploaded file to prepare for reading the contents of the file.

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) LastModified

[DateTime](https://docs.microsoft.com/dotnet/api/system.datetime): Returns the last modified [DateTime](https://docs.microsoft.com/dotnet/api/system.datetime) of the file.

## Methods

### ![](https://1075938901-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F2HvlWXJQMV7DxhGzw7Y1%2Fuploads%2Fgit-blob-2389c55cd19719a73a5ae98e1528c8dc8525cc35%2Finstance.png?alt=media) SaveAs(filename)

Saves the contents of an uploaded file.

| Parameter    | Type                                                          | Description           |
| ------------ | ------------------------------------------------------------- | --------------------- |
| **filename** | [String](https://docs.microsoft.com/dotnet/api/system.string) | The name of the file. |
