读列表库附件地址

来源:互联网 发布:魅族用什么软件root 编辑:程序博客网 时间:2024/05/05 19:17
  1.  if (item.Attachments.Count > 0)
  2.             {
  3.                 for (int a = 0; a < item.Attachments.Count; a++)
  4.                 {
  5.                     if (a == 0)
  6.                     {
  7.                         this.Label1.Text = "附件 1:<a href=" + item.Attachments.UrlPrefix + item.Attachments[a] + " target=_blank>[" + item.Attachments[a] + "]</a><br>";
  8.                     }
  9.                     else if (a == 1)
  10.                     {
  11.                         this.Label2.Text = "附件 2:<a href=" + item.Attachments.UrlPrefix + item.Attachments[a] + " target=_blank>[" + item.Attachments[a] + "]</a><br>";
  12.                     }
  13.                     else if (a == 2)
  14.                     {
  15.                         this.Label3.Text = "附件 3:<a href=" + item.Attachments.UrlPrefix + item.Attachments[a] + " target=_blank>[" + item.Attachments[a] + "]</a>";
  16.                     }
  17.                 }
  18.             }