TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Abhilash J A
505
2.4k
601k
How can pass more than one file type in view to controller ?
Jan 24 2017 4:14 AM
Hello everyone,
In MVC 5, I have view contain 2 file type input control,
@model Reboxwebapp.Models.ViewModel.PartnerVM
@using (Html.BeginForm("Index", "Home", FormMethod.Post, new {
enctype
=
"multipart/form-data"
}))
{
Logo Image:
@Html.TextBoxFor(
model
=
>
model.LogoImage, new {
type
=
"file"
,
id
=
"fileToUploadLogo"
})
Title Picture:
@Html.TextBoxFor(
model
=
>
model.TitlePictureImage, new {
type
=
"file"
,
id
=
"fileToUploadTitle"
})
<
input
type
=
"submit"
value
=
"OK"
/>
}
How can I pass each image to controller?
[HttpPost]
public
ActionResult GetPartner(PartnerVM partnerVM, HttpPostedFileBase fileUpload)
{
partnerBL.LogoImage = ??
partnerBL.TitlePictureImage = ??
}
Please help me...
Reply
Answers (
1
)
Create registration form using db approach in mvc
how to assign linkbutton name in gridview