Exemple #1
0
 /// <summary>
 /// 根据消息类型查找消息并绑定到相应的ListView控件
 /// </summary>
 /// <param name="messageType"></param>
 /// <param name="lv"></param>
 void selectMessage(string messageType, ListView vw)
 {
     dt = MessageManagement.SelectByRecipient("0000000000", getMessageState(), messageType);
     if (dt.Rows.Count == 0)
     {
         SomeMethod.PrintMsgToClient(this.ClientScript, "未查找到消息");
     }
     else
     {
         vw.DataSource = dt;
         vw.DataBind();
     }
 }
Exemple #2
0
 void Bind()
 {
     SomeMethod.IfLogin(this);
     vwNotView.DataSource = MessageManagement.SelectByRecipient(Convert.ToString(Session["memberId"]), "未查看");
     vwNotView.DataBind();
     vwSend.DataSource = MessageManagement.SelectBySender(Convert.ToString(Session["memberId"]));
     vwSend.DataBind();
     vwReview.DataSource = MessageManagement.SelectByRecipient(Convert.ToString(Session["memberId"]), "已查看");
     vwReview.DataBind();
     if (Request["recipient"] != null)
     {
         txtMemberId.Text = Convert.ToString(Request["recipient"]);
     }
 }