private void MyTasks_Load(object sender, EventArgs e) { ICDPacketMgr.GetInst().OnRecv += OnRecv_ICDMessages; FormClosed += delegate { ICDPacketMgr.GetInst().OnRecv -= OnRecv_ICDMessages; Dispose(); //Relese All //Close databases //Close Network Socket Process.GetCurrentProcess().Kill(); }; InitListView(); ICD.HEADER msg = new ICD.HEADER(); msg.FillClientHeader(ICD.DEF.CMD_TaskIDList); ICDPacketMgr.GetInst().sendMsgToServer(msg); /* * ICD.HEADER chatMsg = new ICD.HEADER(); * chatMsg.FillClientHeader(ICD.DEF.CMD_ChatRoomList); * ICDPacketMgr.GetInst().sendMsgToServer(chatMsg); */ }
private void btnUpdate_Click(object sender, EventArgs e) { ICD.HEADER msg = new ICD.HEADER(); msg.FillClientHeader(ICD.DEF.CMD_UserList); ICDPacketMgr.GetInst().sendMsgToServer(msg); }