Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7171935
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T15:30:47+00:00 2026-05-28T15:30:47+00:00

I try to submit a form in Jquery to an Action method in a

  • 0

I try to submit a form in Jquery to an Action method in a Controller.
To do so I serialize my form and use the get method. In the controller I receive my form as a string like param1=1&param2=2….
Is there a way to retrieve directly a FormCollection in my Action Method instead of the string. As my form has many checkboxes it will be easier for me to have it in formCollection.

Here is my Jquery:

 var form = $("#CheckForm");
                    var formCollection = form.serialize();
                    $.post('@Url.Action("CheckSelection")', { clientId: clientId, policyId: policyId, countryCode: country, month: monthtoken[0] + '*' + monthtoken[1], formCollection: formCollection }, function () {
                        alert("formSubmit");
                    });

Here my form:

@using (Html.BeginForm("CheckSelection", "Check", FormMethod.Post, new { id = "CheckForm" }))
{        
<fieldset>
<div class="editor-label">
    @Html.CheckBox("CodeExist",true)
    @Html.Label("Check Code Existence")
</div>
<div class="editor-label">
    @Html.CheckBox("Mandatory",true)
    @Html.Label("Check Code Reccurence")
</div>
<div class="editor-label">
    @Html.CheckBox("Reccurence",true)
    @Html.Label("Check Mandatory Code")
</div>
}

Here is my Action Method:

 [AcceptVerbs(HttpVerbs.Post)]
    public ActionResult CheckSelection(string clientId, string policyId, string countryCode, string month, FormCollection formCollection){}

Thanks in advance for your help!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T15:30:48+00:00Added an answer on May 28, 2026 at 3:30 pm
    var form = $("#CheckForm");
    var formCollection = form.serialize();
    $.post('@Url.Action("CheckSelection")', formCollection , function (data) {
        alert(data); //will alert form submitted
    });
    

    and the controller will look like

    [AcceptVerbs(HttpVerbs.Post)]
    public ActionResult CheckSelection(FormCollection collection){
        return Content("form submitted");
    }
    

    for details of the FormCollection class follow this link

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to use jquery to submit my form like so but it's not
How can I submit jQuery form object (not ajax)? I try form.submit() and it
I am trying to submit a form using jQuery's .ajax() function. It seems like
If have a html form like <form method=POST action=http://.../file.php> <input type=text name=data id=data />
I've a simple form <form action=try.php method=POST> <input id=name name=name type=text placeholder=Name /> <input
I have a rails form with a datetime_select field. When I try to submit
I'm trying to use this tooltip plugin: http://bassistance.de/jquery-plugins/jquery-plugin-tooltip/ . I can't seem to get
I have a form within a SimpleModal modal, but when I try to use
I try to upload file from Dialog (JQuery UI) window like: $( .selector ).dialog(
my form validation does not firing...if i try to submit this form without entering

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.