Unique Calendar for each location

Hello all and thanks in advance for your help.

I am trying to create a calendar for each of my locations

I have added a field in my events database called location.

In Global.asax I added the following

new { controller = “Calendar”, action = “Index”,StoreNo = UrlParameter.Optional }

I am sending localhost/Receive/88 – for location 88

When I try and add an event and step thru it in C# I get null values for

" myevent.StoreNo = RouteData.Values[“StoreNo”].ToString(); "

code below

case “inserted”:

                    myevent = new Event();
                    myevent.start_date = DateTime.Parse(actionValues["start_date"]);
                    myevent.end_date = DateTime.Parse(actionValues["end_date"]);
                    myevent.Descrip = actionValues["text"];
                    myevent.StoreNo = RouteData.Values["StoreNo"].ToString(); //actionValues[RouteData.Values["StoreNo"].ToString()];//something is wrong here

Is there an easier way to do this?


routes.MapRoute( "Receive", "Receive/{StoreNo}", new { controller = "Calendar", action = "Index",StoreNo = UrlParameter.Optional }

for this route StoreNo will be passed only to the Index action of the controller, other actions will have different RouteData, do you have any special route for the save action?