用户
 找回密码
 立即注册
发表于 2016-5-23 10:07:01
poplist给lable控件赋值,如下
  1. private void PopList1_Selected(object sender, EventArgs e)
  2.         {
  3.             try
  4.             {
  5.                 //单项选择lable控件赋值
  6.                 if (PopList1.Selection != null)
  7.                 {
  8.                     this.Label1.Text = PopList1.Selection.Text;
  9.                 }
  10.                 //多项选择lable控件赋值
  11.                 //if (PopList1.Selections != null)
  12.                 //{
  13.                 //    foreach (PopListItem poitem in PopList1.Selections)
  14.                 //    {

  15.                 //        this.Label1.Text = poitem.Text ;
  16.                 //    }
  17.                 //}
  18.             }
  19.             catch (Exception ex)
  20.             {
  21.                 MessageBox.Show(ex.Message);
  22.             }
  23.         }
复制代码


使用道具 举报 回复 支持 反对
发新帖
您需要登录后才可以回帖 登录 | 立即注册