c# - How to make RedirectToAction with multiple parameters and route as UFL -


i'm having bit of trouble routing in .net.

when i'm making redirecttoaction following code:

return redirecttoaction("edit", "add", new { id = newid, someval = newsomeval }); 

and following maproute:

context.maproute(       "editstuff",       "admin/{controller}/{action}/{id}/{someval}",       new { controller = "edit", action = "add", id = @"\d+", someval = @"\d+" }   );   

i redirected url has someval parameter delimited ? instead of /, so: http://localhost:60733/admin/edit/add/43?someval=1
instead of
http://localhost:60733/admin/edit/add/43/1

both links work if access them directly.

can shine light on issue?

many thanks!


Comments

Popular posts from this blog

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -

javascript - firefox memory leak -

Trying to import CSV file to a SQL Server database using asp.net and c# - can't find what I'm missing -