Posted on: 10/7/2011 11:03:43 PM | Views : 239

hello can anyone help me out.  I am trying to retrieve the values I have when a form is submitted but my code doesnt seem to work.  The ID works, but I can't seems to break the loop of the Vlaue to go to the next one.  I just want to be able t0 enter the ID and the value associated with it in the database.  I am using mvc3, vs 2010, c#
the values i am entering are ID and value
ID   =   Value
1     =   5
2     =    10
and so on....

public ActionResult View(FormCollection objCollection)
{
string getID = objCollection[item.ID].TOString();
string getValues = objCollection[item.Value].TOString();

string[] IDs = getID.Split(',');
string[] Valuess = getValues.Split(',');

foreach(string id in getID)
{
      foreach(string value in getValues)
    &nb ...

Go to the complete details ...