<p>How would I go about adding <code>enctype="multipart/form-data"</code> to a form that is generated by using <code>&lt;% Html.BeginForm(); %&gt;</code>?</p>

As part of htmlAttributes,e.g.
```
```
Html.BeginForm(
    action, controller, FormMethod.Post, new { enctype="multipart/form-data"})
```
```
Or you can pass
```
null
```
for action and controller to get the same default target as for BeginForm() without any parameters:
```
```
Html.BeginForm(
    null, null, FormMethod.Post, new { enctype="multipart/form-data"})
```
```