html.actionlink doesn't passing parameter to controller action

Posted by FosterZ on Stack Overflow See other posts from Stack Overflow or by FosterZ
Published on 2010-05-12T14:02:07Z Indexed on 2010/05/12 14:04 UTC
Read the original article Hit count: 229

Filed under:
|

hi, m having problem in passing parameter to controller action, i have done the following


    Url.Action("SchoolDetails","School",new{id=item.SchoolId})

and my controller action follows


    public ActionResult SchoolDetails(string schoolId,_ASI_School schoolDetail)
    {
            schoolDetail = SchoolRepository.GetSchoolById(schoolId);
            return View(schoolDetail);
    }

i dn't know why the schoolId above in action is getting null..

© Stack Overflow or respective owner

Related posts about ASP.NET

Related posts about asp.net-mvc