Solved

mvc, view, asp.net

Posted on 2013-11-06
2
305 Views
Last Modified: 2013-11-22
<form
                                         method="post"
                                         action="/xxx?inputState=@inputState&inputBond=@inputBond"  
                                         enctype="multipart/form-data"
                                         >

How to convert above to @html.begin()?
in razor/c#/asp.net/mvc
0
Comment
Question by:solution1368
2 Comments
 
LVL 16

Expert Comment

by:Stephan
ID: 39630172
How is your route for the form action?
/xxx?inputState=@inputState&inputBond=@inputBond

Open in new window

0
 
LVL 23

Accepted Solution

by:
Ioannis Paraskevopoulos earned 500 total points
ID: 39630203
@using (Html.BeginForm("YourActionName", "YourControllerName", FormMethod.Post, new { enctype = "multipart/form-data" }))
{
    <fieldset>
        @Html.EditorFor(m => m.Phone)
        @Html.EditorFor(m => m.SSN)
        <input type="submit" value="Submit" />
    </fieldset>
}

Open in new window


Just replace YourActionName and YourControllerName with the appropriate values.

Giannis
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

For those of you who don't follow the news, or just happen to live under rocks, Microsoft Research released a beta SDK (http://www.microsoft.com/en-us/download/details.aspx?id=27876) for the Xbox 360 Kinect. If you don't know what a Kinect is (http:…
Introduction This article shows how to use the open source plupload control to upload multiple images. The images are resized on the client side before uploading and the upload is done in chunks. Background I had to provide a way for user…
This Micro Tutorial will give you a basic overview how to record your screen with Microsoft Expression Encoder. This program is still free and open for the public to download. This will be demonstrated using Microsoft Expression Encoder 4.
Video by: Mark
This lesson goes over how to construct ordered and unordered lists and how to create hyperlinks.

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now