Our webform (ProcessStudent.aspx
) is designed to receive three parameters in the QueryString
: Name, Grade, Class. Page_Load
retrieves these three parameters and sends it to a method SaveStudent
(ie. SaveStudent(name, grade, class);
).
I need to process several three-parameter combinations for one page. I basically copied/pasted ProcessStudent.aspx
, but I need to modify the way I read the parameters. I can change the URL structure, but everything else needs to stay the same.
So my initial thought was to include these combinations in the URL; for example, each value would be separated by a char and each combination by another char. Something like this, which I would then parse :
ProcessStudent.aspx?Students=Joe|5|Science,Bob|6|Math,Mary|5|English
Would something like this work? Is there a better way?