Click here to Skip to main content
15,029,736 members
Home / Discussions / Web Development
   

Web Development

 
AnswerRe: Error When click on login in MVC4 Pin
Dominic Burford10-Oct-14 4:52
professionalDominic Burford10-Oct-14 4:52 
QuestionGet Page Markup Pin
ASPnoob8-Oct-14 14:14
MemberASPnoob8-Oct-14 14:14 
AnswerRe: Get Page Markup Pin
Graham Breach8-Oct-14 22:25
MemberGraham Breach8-Oct-14 22:25 
QuestionIssue while using MSSOAPINIT method of SOAP Object in .ASP Pin
DibenduC7-Oct-14 23:39
MemberDibenduC7-Oct-14 23:39 
QuestionSending mail from a webpage using servlet Pin
Meghamaalaa7-Oct-14 1:51
MemberMeghamaalaa7-Oct-14 1:51 
QuestionWierd issue with responsive layout - CSS Pin
Member 111144085-Oct-14 8:50
MemberMember 111144085-Oct-14 8:50 
AnswerRe: Wierd issue with responsive layout - CSS Pin
Member 111144085-Oct-14 11:56
MemberMember 111144085-Oct-14 11:56 
QuestionHow can i Post Radio Button List with Dynamic names to controller Pin
Mujtaba 103885433-Oct-14 20:24
professionalMujtaba 103885433-Oct-14 20:24 
Hi everyone.
I am well and truly stuck Frown | :( .
I have created a huge list of radio buttons on my razor view. Each row is a different set of radio buttons and I have given them each dynamic names.
I am new to MVC and i did not know how i can pass this radio button list to controller

this is my editor template

@model StudentManagement1.TeacherCourseStudent
@{
    ViewBag.Title = "Attendance";
}
 

<tr>
    
    
    <td>
       @Model.Student_Id
    </td>
 
    <td>
        @Model.Student.Name
    </td>
 
    <td>
        @Model.Student.Sur_Name
    </td>
 
    <td>
       @Model.Student.Semester.Semester_Name
    </td>
 
    <td>
    @Html.RadioButton(@Model.Student_Id.ToString(), "present", true)
    </td>
 
    <td>
    @Html.RadioButton(@Model.Student_Id.ToString(), "absent")
    </td>
 
    <td>
    @Html.RadioButton(@Model.Student_Id.ToString(), "leave")
    </td>


and this is my Razor view

@model IEnumerable<StudentManagement1.TeacherCourseStudent>
@{
ViewBag.Title = "MarkAttendance";
Layout = "~/Views/Shared/_TeacherLayout.cshtml";
}

@using (Html.BeginForm("MarkAttendance", "Attendance", FormMethod.Post))
{


<table>
<tr>
<th>
Student Id
</th>
<th>
Name
</th>
<th>
Sur Name
</th>
<th>
Semester
</th>
<th>
Present
</th>
<th>
Absent
</th>
<th>
Leave
</th>


</tbody>
@Html.EditorForModel()
</table>
<br /> <br />
<input type="submit" value="Save attendance" />
}

here my controller to which i want to pass values

[HttpPost]
public ActionResult MarkAttendance(IEnumerable<string> Student_Id)
{
return view();
}

modified 4-Oct-14 6:34am.

Questionhelp w/js Pin
Charlie Kirk26-Sep-14 15:08
MemberCharlie Kirk26-Sep-14 15:08 
SuggestionRe: help w/js Pin
Kornfeld Eliyahu Peter28-Sep-14 1:40
professionalKornfeld Eliyahu Peter28-Sep-14 1:40 
AnswerRe: help w/js Pin
Charlie Kirk6-Oct-14 15:01
MemberCharlie Kirk6-Oct-14 15:01 
Questionmysqli truncate Pin
Charlie Kirk26-Sep-14 15:02
MemberCharlie Kirk26-Sep-14 15:02 
AnswerRe: mysqli truncate Pin
Kornfeld Eliyahu Peter28-Sep-14 1:39
professionalKornfeld Eliyahu Peter28-Sep-14 1:39 
Questioncontinuously scroll multiple pictures on a web page using c# and html Pin
Mike Margolius24-Sep-14 8:20
professionalMike Margolius24-Sep-14 8:20 
AnswerRe: continuously scroll multiple pictures on a web page using c# and html Pin
Ali Al Omairi(Abu AlHassan)24-Sep-14 8:57
professionalAli Al Omairi(Abu AlHassan)24-Sep-14 8:57 
GeneralRe: continuously scroll multiple pictures on a web page using c# and html Pin
Mike Margolius24-Sep-14 9:33
professionalMike Margolius24-Sep-14 9:33 
GeneralRe: continuously scroll multiple pictures on a web page using c# and html Pin
Ali Al Omairi(Abu AlHassan)28-Sep-14 0:49
professionalAli Al Omairi(Abu AlHassan)28-Sep-14 0:49 
AnswerRe: continuously scroll multiple pictures on a web page using c# and html Pin
Richard Deeming24-Sep-14 12:19
mveRichard Deeming24-Sep-14 12:19 
Questionopacity inheritance Pin
Ali Al Omairi(Abu AlHassan)24-Sep-14 1:20
professionalAli Al Omairi(Abu AlHassan)24-Sep-14 1:20 
Questionreload data into gridview control based upon user selection criteria Pin
dcof21-Sep-14 14:42
Memberdcof21-Sep-14 14:42 
QuestionHow to add/update/delete content txt file? Pin
Member 1039071520-Sep-14 4:38
MemberMember 1039071520-Sep-14 4:38 
AnswerRe: How to add/update/delete content txt file? Pin
Richard MacCutchan20-Sep-14 21:09
mveRichard MacCutchan20-Sep-14 21:09 
SuggestionRe: How to add/update/delete content txt file? Pin
Kornfeld Eliyahu Peter20-Sep-14 22:14
professionalKornfeld Eliyahu Peter20-Sep-14 22:14 
Questionhow c++ client calls the js function which is in the firefox extension Pin
l3563319-Sep-14 0:51
Memberl3563319-Sep-14 0:51 
QuestionAny latest UI framework Pin
npatel1234518-Sep-14 7:05
Membernpatel1234518-Sep-14 7:05 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.