Saturday, 15 September 2012

c# - RedirectToAction not passing parameters MVC -



c# - RedirectToAction not passing parameters MVC -

i have action takes list of model items , delete them, question , why parameters not getting passed

public actionresult deletemultiple(ienumerable<qamodel> model) { _qaservice.deletemultiple(model); long subscriptionid = model.first().subscriptionid; //value available here long languageid = model.first().languageid; //value available here homecoming redirecttoaction("index", new { subscriptionid =subscriptionid, languageid =languageid,message="data deleted ."}); }

//redirection happens value getting null within index method.

public actionresult index(int? subscriptionid,int? languageid,string message) { }

what doing wrong can 1 please help me stuff.

redirecttoaction returns 302 browser causes request browser, info not retained.

if want phone call method phone call method , avoid round trip browser.

return index(...)

c# asp.net-mvc asp.net-mvc-5

No comments:

Post a Comment