小编Sim*_*mon的帖子

添加到会话ASP.NET C#

我想添加一个会话["i"],结果更多

目前它只会显示一组结果

例如,School1 11/10/2011 14/11/2011 GCSE AAA

我想添加更多集,但它们似乎没有存储在Session中

例如

School1 11/10/2011 14/11/2011 GCSE AAA

School2 11/10/2012 14/11/2012 ALevels AAA

Education addResults = new Education(schoolName, fromDate, toDate , qualification , grades);

Session["i"] = (addResults );

//schoolarraylist.Add(addResults );

foreach (Education currentschool in schoolarraylist)
      {
         Session["i"] = currentschool.Schoollocation + "," + currentschool.Datefrom + "," + currentschool.Dateto + "," + currentschool.Qualifications + "," + currentschool.Grade + "<br />";

           string tmp = Session["i"].ToString();
           string[] sb = tmp.Split(',');
           string [] ii = new string[sb.GetUpperBound(0) + 1]; …
Run Code Online (Sandbox Code Playgroud)

c# asp.net session

1
推荐指数
1
解决办法
131
查看次数

标签 统计

asp.net ×1

c# ×1

session ×1