Database1Entities db = new Database1Entities(); protected void Page_Load(object sender, EventArgs e) { var ddd = from a in db.Table.ToList() let ad = Get(a.Name) select new { n = ad[0], nn = ad[1] }; GridView1.DataSource = ddd; GridView1.DataBind(); } public string[] Get(string aaa) { return new string[] { "1", "2" }; }
简单 看下就够了!!
时间: 2024-10-15 15:23:47