コード例 #1
0
 private void BindShow(string str)
 {
     if (str != "")
     {
         List <Tz888.Model.news.UpImages> list = new List <Tz888.Model.news.UpImages>();
         string[] num = str.Split('$');
         for (int i = 0; i < num.Length; i++)
         {
             if (num[i].Trim() != "")
             {
                 Tz888.Model.news.UpImages imagemodel = new Tz888.Model.news.UpImages();
                 imagemodel.Descript = num[i].ToString().Trim();
                 list.Add(imagemodel);
             }
         }
         this.DataList1.DataSource = list;
         this.DataList1.DataBind();
     }
 }
コード例 #2
0
 private void BindShow(string str)
 {
     sed = newstabbll.GetNewsTabByNewId(int.Parse(str)).Imagesurls.Trim();
     if (sed != "NULL")
     {
         List <Tz888.Model.news.UpImages> list = new List <Tz888.Model.news.UpImages>();
         string[] num = sed.Split('$');
         for (int i = 0; i < num.Length; i++)
         {
             if (num[i].Trim() != "")
             {
                 Tz888.Model.news.UpImages imagemodel = new Tz888.Model.news.UpImages();
                 imagemodel.Descript = num[i].ToString().Trim();
                 list.Add(imagemodel);
             }
         }
         this.DataList1.DataSource = list;
         this.DataList1.DataBind();
     }
 }