Exemplo n.º 1
0
        //退出讨论组
        private void button12_Click(object sender, EventArgs e)
        {
            if (string.IsNullOrWhiteSpace(this.textBox15.Text))
            {
                MessageBox.Show("目标讨论组不能为空");
                return;
            }
            int content = coolQApiForTest.SetDiscussLeave(Convert.ToInt64(this.textBox15.Text));

            textBox4.Text = "" + content;
            MessageBox.Show("执行完成");
        }
Exemplo n.º 2
0
 /// <summary>
 /// 处理讨论组消息
 /// </summary>
 /// <param name="subType">消息类型,目前固定为1</param>
 /// <param name="sendTime">消息发送时间(时间戳)</param>
 /// <param name="fromDiscuss">来源讨论组</param>
 /// <param name="fromQq">来源QQ</param>
 /// <param name="msg">消息内容</param>
 /// <param name="font">消息字体</param>
 /// <returns> 0 - 忽略消息 ; 1 - 拦截消息 </returns>
 public override int ProcessDiscussGroupMessage(int subType, int sendTime, long fromDiscuss, long fromQq, string msg, int font)
 {
     CoolQApi.SetDiscussLeave(fromDiscuss);
     return(1);
 }