private void backgroundWorkerUserQuery_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e)
        {
            CEnum.Message_Body[,] mResult = (CEnum.Message_Body[, ])e.Result;
            PnlPage.Visible = false;
            if (mResult[0, 0].eName == CEnum.TagName.ERROR_Msg)
            {
                MessageBox.Show(mResult[0, 0].oContent.ToString());
                return;
            }

            Operation_FJ.BuildDataTable(this.m_ClientEvent, mResult, GrdResult, out iPageCount);

            if (iPageCount <= 0)
            {
                PnlPage.Visible = false;
            }
            else
            {
                for (int i = 0; i < iPageCount; i++)
                {
                    CmbPage.Items.Add(i + 1);
                }

                CmbPage.SelectedIndex = 0;
                bFirst          = true;
                PnlPage.Visible = true;
            }
        }
Exemplo n.º 2
0
        private void BtnSearch_Click(object sender, EventArgs e)
        {
            if (comboBox1.Text.Length > 0)
            {
                BtnSearch.Enabled = false;
                CEnum.Message_Body[] mContent = new CEnum.Message_Body[4];

                mContent[0].eName    = CEnum.TagName.FJ_ServerIP;
                mContent[0].eTag     = CEnum.TagFormat.TLV_STRING;
                mContent[0].oContent = Operation_FJ.GetItemAddr(mServerInfo, CmbServer.Text);

                mContent[1].eName    = CEnum.TagName.Index;
                mContent[1].eTag     = CEnum.TagFormat.TLV_INTEGER;
                mContent[1].oContent = 1;

                mContent[2].eName    = CEnum.TagName.PageSize;
                mContent[2].eTag     = CEnum.TagFormat.TLV_INTEGER;
                mContent[2].oContent = 100;

                mContent[3].eName    = CEnum.TagName.FJ_Max;
                mContent[3].eTag     = CEnum.TagFormat.TLV_INTEGER;
                mContent[3].oContent = ReturnType(comboBox1.Text.Trim());


                this.backgroundWorkerSearch.RunWorkerAsync(mContent);
            }
            else
            {
                MessageBox.Show("请输入查询类型");
            }
        }
        private void UserLoginQuery()
        {
            GrdResult.DataSource = null;
            CEnum.Message_Body[] mContent = new CEnum.Message_Body[6];

            mContent[0].eName    = CEnum.TagName.FJ_UserNick;
            mContent[0].eTag     = CEnum.TagFormat.TLV_STRING;
            mContent[0].oContent = userAccount;

            mContent[1].eName    = CEnum.TagName.FJ_ServerIP;
            mContent[1].eTag     = CEnum.TagFormat.TLV_STRING;
            mContent[1].oContent = Operation_FJ.GetItemAddr(mServerInfo, CmbServer.Text);

            mContent[2].eName    = CEnum.TagName.Index;
            mContent[2].eTag     = CEnum.TagFormat.TLV_INTEGER;
            mContent[2].oContent = 1;

            mContent[3].eName    = CEnum.TagName.PageSize;
            mContent[3].eTag     = CEnum.TagFormat.TLV_INTEGER;
            mContent[3].oContent = Operation_FJ.iPageSize;

            mContent[4].eName    = CEnum.TagName.FJ_StartTime;
            mContent[4].eTag     = CEnum.TagFormat.TLV_DATE;
            mContent[4].oContent = DtpBegin.Value;

            mContent[5].eName    = CEnum.TagName.FJ_EndTime;
            mContent[5].eTag     = CEnum.TagFormat.TLV_DATE;
            mContent[5].oContent = DtpEnd.Value;

            this.backgroundWorkerUserQuery.RunWorkerAsync(mContent);
        }
        private void CmbPage_SelectedIndexChanged_1(object sender, EventArgs e)
        {
            if (bFirst)
            {
                //this.CmbPage.Enabled = false;
                //this.Cursor = Cursors.AppStarting;
                CEnum.Message_Body[] mContent = new CEnum.Message_Body[6];

                mContent[0].eName    = CEnum.TagName.FJ_UserID;
                mContent[0].eTag     = CEnum.TagFormat.TLV_STRING;
                mContent[0].oContent = userAccount;

                mContent[1].eName    = CEnum.TagName.FJ_ServerIP;
                mContent[1].eTag     = CEnum.TagFormat.TLV_STRING;
                mContent[1].oContent = Operation_FJ.GetItemAddr(mServerInfo, CmbServer.Text);

                mContent[2].eName    = CEnum.TagName.Index;
                mContent[2].eTag     = CEnum.TagFormat.TLV_INTEGER;
                mContent[2].oContent = (int.Parse(CmbPage.Text) - 1) * Operation_FJ.iPageSize + 1;

                mContent[3].eName    = CEnum.TagName.PageSize;
                mContent[3].eTag     = CEnum.TagFormat.TLV_INTEGER;
                mContent[3].oContent = Operation_FJ.iPageSize;

                mContent[4].eName    = CEnum.TagName.FJ_StartTime;
                mContent[4].eTag     = CEnum.TagFormat.TLV_DATE;
                mContent[4].oContent = DtpBegin.Value;

                mContent[5].eName    = CEnum.TagName.FJ_EndTime;
                mContent[5].eTag     = CEnum.TagFormat.TLV_DATE;
                mContent[5].oContent = DtpEnd.Value;

                this.backgroundWorkerPageChanged.RunWorkerAsync(mContent);
            }
        }
        private void backgroundWorkerSearch_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e)
        {
            this.BtnSearch.Enabled        = true;
            this.Cursor                   = Cursors.Default;
            CEnum.Message_Body[,] mResult = (CEnum.Message_Body[, ])e.Result;

            if (mResult[0, 0].eName == CEnum.TagName.ERROR_Msg)
            {
                MessageBox.Show(mResult[0, 0].oContent.ToString());
                return;
            }

            Operation_FJ.BuildDataTable(this.m_ClientEvent, mResult, RoleInfoView, out iPageCount);

            //if (iPageCount <= 0)
            //{
            //    PnlPage.Visible = false;
            //}
            //else
            //{
            //    for (int i = 0; i < iPageCount; i++)
            //    {
            //        CmbPage.Items.Add(i + 1);
            //    }

            //    CmbPage.SelectedIndex = 0;
            //    bFirst = true;
            //    PnlPage.Visible = true;
            //}
        }
 private void backgroundWorkerPageChanged_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e)
 {
     this.CmbPage.Enabled             = true;
     this.Cursor                      = Cursors.Default;
     CEnum.Message_Body[,] mGetResult = (CEnum.Message_Body[, ])e.Result;
     Operation_FJ.BuildDataTable(this.m_ClientEvent, mGetResult, GrdResult, out iPageCount);
 }
        private void BtnSearch_Click(object sender, EventArgs e)
        {
            if (CmbServer.Text == "")
            {
                return;
            }
            PnlPage.Visible      = false;
            GrdResult.DataSource = null;

            if (TxtAccount.Text.Trim().Length > 0)
            {
                this.BtnSearch.Enabled = false;
                this.Cursor            = Cursors.AppStarting;
                //CEnum.Message_Body[] mContent = new CEnum.Message_Body[6];

                //mContent[0].eName = CEnum.TagName.FJ_UserID;
                //mContent[0].eTag = CEnum.TagFormat.TLV_STRING;
                //mContent[0].oContent = TxtAccount.Text;

                //mContent[1].eName = CEnum.TagName.FJ_ServerIP;
                //mContent[1].eTag = CEnum.TagFormat.TLV_STRING;
                //mContent[1].oContent = Operation_FJ.GetItemAddr(mServerInfo, CmbServer.Text);

                //mContent[2].eName = CEnum.TagName.Index;
                //mContent[2].eTag = CEnum.TagFormat.TLV_INTEGER;
                //mContent[2].oContent = 1;

                //mContent[3].eName = CEnum.TagName.PageSize;
                //mContent[3].eTag = CEnum.TagFormat.TLV_INTEGER;
                //mContent[3].oContent = Operation_FJ.iPageSize;

                //mContent[4].eName = CEnum.TagName.FJ_StartTime;
                //mContent[4].eTag = CEnum.TagFormat.TLV_DATE;
                //mContent[4].oContent = DtpBegin.Value;

                //mContent[5].eName = CEnum.TagName.FJ_EndTime;
                //mContent[5].eTag = CEnum.TagFormat.TLV_DATE;
                //mContent[5].oContent = DtpEnd.Value;

                CEnum.Message_Body[] mContent = new CEnum.Message_Body[3];

                mContent[0].eName    = CEnum.TagName.FJ_UserID;
                mContent[0].eTag     = CEnum.TagFormat.TLV_STRING;
                mContent[0].oContent = TxtAccount.Text;

                mContent[1].eName    = CEnum.TagName.FJ_ServerIP;
                mContent[1].eTag     = CEnum.TagFormat.TLV_STRING;
                mContent[1].oContent = Operation_FJ.GetItemAddr(mServerInfo, CmbServer.Text);

                mContent[2].eName    = CEnum.TagName.FJ_UserNick;
                mContent[2].eTag     = CEnum.TagFormat.TLV_STRING;
                mContent[2].oContent = "";

                this.backgroundWorkerSearch.RunWorkerAsync(mContent);
            }
            else
            {
                MessageBox.Show("请输入玩家帐号");
            }
        }
Exemplo n.º 8
0
        private void button1_Click(object sender, EventArgs e)
        {
            Cursor          = Cursors.WaitCursor;
            button1.Enabled = false;

            CEnum.Message_Body[] mContent = new CEnum.Message_Body[4];
            mContent[0].eName    = CEnum.TagName.FJ_ServerIP;
            mContent[0].eTag     = CEnum.TagFormat.TLV_STRING;
            mContent[0].oContent = Operation_FJ.GetItemAddr(mServerInfo, CmbServer.Text);

            mContent[1].eName    = CEnum.TagName.FJ_UseAccount;
            mContent[1].eTag     = CEnum.TagFormat.TLV_STRING;
            mContent[1].oContent = TxtAccount.Text.Trim();


            mContent[2].eName    = CEnum.TagName.FJ_Pwd;
            mContent[2].eTag     = CEnum.TagFormat.TLV_STRING;
            mContent[2].oContent = this.TxtTmpPwd.Text.Trim();

            mContent[3].eName    = CEnum.TagName.UserByID;
            mContent[3].eTag     = CEnum.TagFormat.TLV_INTEGER;
            mContent[3].oContent = int.Parse(m_ClientEvent.GetInfo("USERID").ToString());

            this.backgroundWorkerModify.RunWorkerAsync(mContent);
        }
Exemplo n.º 9
0
 private void backgroundWorkerSearch_DoWork(object sender, DoWorkEventArgs e)
 {
     lock (typeof(C_Event.CSocketEvent))
     {
         mResult = Operation_FJ.GetResult(tmp_ClientEvent, CEnum.ServiceKey.FJ_TempPassword_Query, (CEnum.Message_Body[])e.Argument);
     }
 }
        private void backgroundWorkerFormLoad_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e)
        {
            CmbServer = Operation_FJ.BuildCombox(mServerInfo, CmbServer);


            tmp_ClientEvent = m_ClientEvent.GetSocket(m_ClientEvent, Operation_FJ.GetItemAddr(mServerInfo, CmbServer.Text));
        }
        private void FrmNewMission_Load(object sender, EventArgs e)
        {
            IntiFontLib();

            CEnum.Message_Body[] mContent = new CEnum.Message_Body[1];


            mContent[0].eName    = CEnum.TagName.FJ_Level;
            mContent[0].eTag     = CEnum.TagFormat.TLV_INTEGER;
            mContent[0].oContent = this.level;

            this.mTaskInfo = Operation_FJ.GetResult(this.m_ClientEvent, CEnum.ServiceKey.FJ_QuestTable_Query, mContent);
            if (mTaskInfo[0, 0].eName == CEnum.TagName.ERROR_Msg)
            {
                MessageBox.Show(mTaskInfo[0, 0].oContent.ToString());
                this.Close();
                return;
            }
            else
            {
                this.textBoxNick.Text   = this.nickName;
                this.comboBoxState.Text = this.state;
                this.comboBoxTaskID.Items.Clear();
                this.comboBoxTaskName.Items.Clear();
                for (int i = 0; i < mTaskInfo.GetLength(0); i++)
                {
                    this.comboBoxTaskID.Items.Add(mTaskInfo[i, 0].oContent.ToString());
                    this.comboBoxTaskName.Items.Add(mTaskInfo[i, 1].oContent.ToString());
                }
                this.comboBoxTaskID.Text   = this.questID;
                this.comboBoxTaskName.Text = this.content;
                this.comboBoxTaskID.Tag    = mTaskInfo;
                this.comboBoxTaskName.Tag  = mTaskInfo;
            }
        }
Exemplo n.º 12
0
 private void backgroundWorkerStatusQuery_DoWork(object sender, DoWorkEventArgs e)
 {
     lock (typeof(C_Event.CSocketEvent))
     {
         e.Result = Operation_FJ.GetResult(tmp_ClientEvent, CEnum.ServiceKey.FJ_UserBan_Query, (CEnum.Message_Body[])e.Argument);
     }
 }
Exemplo n.º 13
0
 private void backgroundWorkerType_DoWork(object sender, DoWorkEventArgs e)
 {
     lock (typeof(C_Event.CSocketEvent))
     {
         mType = Operation_FJ.GetResult(this.m_ClientEvent, CEnum.ServiceKey.FJ_ItemLogType_Query, (CEnum.Message_Body[])e.Argument);
     }
 }
        private void dgvMission_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
        {
            if (e.RowIndex >= 0)
            {
                DataTable     dt  = ((DataTable)dgvMission.DataSource);
                FrmNewMission fnw = new FrmNewMission(this.tmp_ClientEvent,
                                                      dt.Rows[e.RowIndex][0].ToString(),
                                                      Operation_FJ.GetItemAddr(mServerInfo, CmbServer.Text),
                                                      dt.Rows[e.RowIndex][1].ToString(),
                                                      dt.Rows[e.RowIndex][3].ToString(),
                                                      dt.Rows[e.RowIndex][2].ToString(),
                                                      this.level);

                fnw.ShowDialog();



                this.Cursor = Cursors.WaitCursor;
                CEnum.Message_Body[] mContent = new CEnum.Message_Body[2];


                mContent[0].eName    = CEnum.TagName.FJ_ServerIP;
                mContent[0].eTag     = CEnum.TagFormat.TLV_STRING;
                mContent[0].oContent = Operation_FJ.GetItemAddr(mServerInfo, CmbServer.Text);

                mContent[1].eName          = CEnum.TagName.FJ_UserNick;
                mContent[1].eTag           = CEnum.TagFormat.TLV_STRING;
                mContent[1].oContent       = ((DataTable)this.dgvMission.DataSource).Rows[e.RowIndex][0].ToString();
                this.dgvMission.DataSource = null;

                this.backgroundWorkerMissionQuery.RunWorkerAsync(mContent);
            }
        }
Exemplo n.º 15
0
        private void BtnSave_Click(object sender, EventArgs e)
        {
            strUserNick = TxtNick.Text.Trim();
            if (strUserNick != "" && txtUnReason.Text.Trim() != "")
            {
                if (MessageBox.Show(config.ReadConfigValue("MFj", "BA_Code_MsgUnlock"), config.ReadConfigValue("MFj", "BA_Code_MsgAccont"), MessageBoxButtons.YesNo) == DialogResult.Yes)
                {
                    this.BtnSave.Enabled = false;
                    this.Cursor          = Cursors.AppStarting;
                    CEnum.Message_Body[] mContent = new CEnum.Message_Body[4];
                    mContent[0].eName    = CEnum.TagName.FJ_ServerIP;
                    mContent[0].eTag     = CEnum.TagFormat.TLV_STRING;
                    mContent[0].oContent = Operation_FJ.GetItemAddr(mServerInfo, CmbServer.Text);

                    mContent[1].eName    = CEnum.TagName.FJ_UserID;
                    mContent[1].eTag     = CEnum.TagFormat.TLV_STRING;
                    mContent[1].oContent = strUserNick;

                    mContent[2].eName    = CEnum.TagName.UserByID;
                    mContent[2].eTag     = CEnum.TagFormat.TLV_INTEGER;
                    mContent[2].oContent = int.Parse(m_ClientEvent.GetInfo("USERID").ToString());

                    mContent[3].eName    = CEnum.TagName.FJ_Reason;
                    mContent[3].eTag     = CEnum.TagFormat.TLV_STRING;
                    mContent[3].oContent = txtUnReason.Text.Trim();

                    this.backgroundWorkerUnFreeze.RunWorkerAsync(mContent);
                }
            }
            else
            {
                MessageBox.Show(config.ReadConfigValue("MFj", "BA_Code_MsgReason"));
            }
        }
Exemplo n.º 16
0
        private void button1_Click(object sender, EventArgs e)
        {
            button1.Enabled = false;
            //Cursor = Cursors.AppStarting;
            strDBip = Operation_FJ.GetItemAddr(mServerInfo, CmbServer.Text);
            strUser = textBox1.Text;


            CEnum.Message_Body[,] mResult;
            CEnum.Message_Body[] mContent = new CEnum.Message_Body[4];
            mContent[0].eName    = CEnum.TagName.FJ_ServerIP;
            mContent[0].eTag     = CEnum.TagFormat.TLV_STRING;
            mContent[0].oContent = strDBip;

            mContent[1].eName    = CEnum.TagName.Index;
            mContent[1].eTag     = CEnum.TagFormat.TLV_INTEGER;
            mContent[1].oContent = 1;

            mContent[2].eName    = CEnum.TagName.PageSize;
            mContent[2].eTag     = CEnum.TagFormat.TLV_INTEGER;
            mContent[2].oContent = Operation_FJ.iPageSize;

            mContent[3].eName    = CEnum.TagName.FJ_UserID;
            mContent[3].eTag     = CEnum.TagFormat.TLV_STRING;
            mContent[3].oContent = strUser;

            this.backgroundWorkerStatusQuery.RunWorkerAsync(mContent);
        }
Exemplo n.º 17
0
        /// <summary>
        /// 请求频道名称
        /// </summary>
        private void GetChannelList()
        {
            CEnum.Message_Body[] mContent = new CEnum.Message_Body[2];
            mContent[0].eName    = CEnum.TagName.ServerInfo_GameDBID;
            mContent[0].eTag     = CEnum.TagFormat.TLV_INTEGER;
            mContent[0].oContent = 2;

            mContent[1].eName    = CEnum.TagName.ServerInfo_GameID;
            mContent[1].eTag     = CEnum.TagFormat.TLV_INTEGER;
            mContent[1].oContent = m_ClientEvent.GetInfo("GameID_FJ");

            lock (typeof(C_Event.CSocketEvent))
            {
                mChannelInfo = Operation_FJ.GetServerList(this.m_ClientEvent, mContent);
            }
            if (mChannelInfo[0, 0].eName == CEnum.TagName.ERROR_Msg)
            {
                MessageBox.Show(mChannelInfo[0, 0].oContent.ToString());
                return;
            }

            this.CmbServer = Operation_FJ.BuildCombox(mChannelInfo, CmbServer);
            bFirst         = true;

            tmp_ClientEvent = m_ClientEvent.GetSocket(m_ClientEvent, Operation_FJ.GetItemAddr(mChannelInfo, CmbServer.Text));
        }
Exemplo n.º 18
0
        private void backgroundWorkerSearch_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e)
        {
            this.Btn_Search.Enabled          = true;
            this.Cursor                      = Cursors.Default;
            CEnum.Message_Body[,] mGetResult = (CEnum.Message_Body[, ])e.Result;
            //ÎÞÄÚÈÝÏÔʾ
            if (mGetResult[0, 0].eName == CEnum.TagName.ERROR_Msg)
            {
                MessageBox.Show(mGetResult[0, 0].oContent.ToString());
                return;
            }

            Operation_FJ.BuildDataTable(this.m_ClientEvent, mGetResult, GrdList, out iPageCount);

            if (iPageCount <= 0)
            {
                PnlPage.Visible = false;
            }
            else
            {
                for (int i = 0; i < iPageCount; i++)
                {
                    CmbPage.Items.Add(i + 1);
                }

                CmbPage.SelectedIndex = 0;
                bFirst          = true;
                PnlPage.Visible = true;
            }
        }
Exemplo n.º 19
0
 private void backgroundWorkerFormLoad_DoWork(object sender, DoWorkEventArgs e)
 {
     lock (typeof(C_Event.CSocketEvent))
     {
         mServerInfo = Operation_FJ.GetServerList(this.m_ClientEvent, (CEnum.Message_Body[])e.Argument);
     }
 }
 private void backgroundWorkerUpdate_DoWork(object sender, DoWorkEventArgs e)
 {
     lock (typeof(C_Event.CSocketEvent))
     {
         e.Result = Operation_FJ.GetResult(tmp_ClientEvent, CEnum.ServiceKey.FJ_PlayPosition_Update, (CEnum.Message_Body[])e.Argument);
     }
 }
Exemplo n.º 21
0
        private void CmbServer_SelectedIndexChanged(object sender, EventArgs e)
        {
            if (bFirst)
            {
                TxtCode.Items.Clear();
                CEnum.Message_Body[] mContent = new CEnum.Message_Body[1];

                mContent[0].eName    = CEnum.TagName.FJ_ServerIP;
                mContent[0].eTag     = CEnum.TagFormat.TLV_STRING;
                mContent[0].oContent = Operation_FJ.GetItemAddr(mChannelInfo, CmbServer.Text);

                CEnum.Message_Body[,] GsResult = null;
                lock (typeof(C_Event.CSocketEvent))
                {
                    GsResult = Operation_FJ.GetResult(tmp_ClientEvent, CEnum.ServiceKey.FJ_GS_Query, mContent);
                }
                if (GsResult[0, 0].eName == CEnum.TagName.ERROR_Msg)
                {
                    MessageBox.Show(GsResult[0, 0].oContent.ToString());
                    return;
                }
                for (int i = 0; i < GsResult.GetLength(0); i++)
                {
                    TxtCode.Items.Add(GsResult[i, 0].oContent.ToString());
                }
            }
        }
Exemplo n.º 22
0
        private void PartInfo()
        {
            this.RoleInfoView.DataSource  = null;
            CEnum.Message_Body[,] mResult = null;
            CEnum.Message_Body[] mContent = new CEnum.Message_Body[3];

            mContent[0].eName    = CEnum.TagName.FJ_UserID;
            mContent[0].eTag     = CEnum.TagFormat.TLV_STRING;
            mContent[0].oContent = TxtAncont.Text;

            mContent[1].eName    = CEnum.TagName.FJ_ServerIP;
            mContent[1].eTag     = CEnum.TagFormat.TLV_STRING;
            mContent[1].oContent = Operation_FJ.GetItemAddr(mServerInfo, CmbServer.Text);

            mContent[2].eName    = CEnum.TagName.FJ_UserNick;
            mContent[2].eTag     = CEnum.TagFormat.TLV_STRING;
            mContent[2].oContent = TxtNick.Text;

            lock (typeof(C_Event.CSocketEvent))
            {
                mResult = Operation_FJ.GetResult(tmp_ClientEvent, CEnum.ServiceKey.FJ_CharacterInfo_Query, mContent);
            }


            if (mResult[0, 0].eName == CEnum.TagName.ERROR_Msg)
            {
                MessageBox.Show(mResult[0, 0].oContent.ToString());
                this.BtnSearch.Enabled = true;
                return;
            }

            Operation_FJ.BuildDataTable(this.m_ClientEvent, mResult, RoleInfoView, out iPageCount);
            this.BtnSearch.Enabled = true;
        }
Exemplo n.º 23
0
 private void backgroundWorkerAccont_DoWork(object sender, DoWorkEventArgs e)
 {
     lock (typeof(C_Event.CSocketEvent))
     {
         e.Result = Operation_FJ.GetResult(m_ClientEvent, CEnum.ServiceKey.FJ_AccountActive_Query, (CEnum.Message_Body[])e.Argument);
     }
 }
Exemplo n.º 24
0
        private void BtnSearch_Click(object sender, EventArgs e)
        {
            if (CmbServer.Text == "")
            {
                return;
            }
            //清除控件

            this.TxtTmpPwd.Text = "";

            if (TxtAccount.Text.Trim().Length > 0)
            {
                this.BtnSearch.Enabled = false;
                this.Cursor            = Cursors.AppStarting;

                CEnum.Message_Body[] mContent = new CEnum.Message_Body[2];
                mContent[0].eName    = CEnum.TagName.FJ_ServerIP;
                mContent[0].eTag     = CEnum.TagFormat.TLV_STRING;
                mContent[0].oContent = Operation_FJ.GetItemAddr(mServerInfo, CmbServer.Text);

                mContent[1].eName    = CEnum.TagName.FJ_UseAccount;
                mContent[1].eTag     = CEnum.TagFormat.TLV_STRING;
                mContent[1].oContent = TxtAccount.Text.Trim();

                this.backgroundWorkerSearch.RunWorkerAsync(mContent);
            }
            else
            {
                MessageBox.Show(config.ReadConfigValue("MSDO", "CI_Code_inPutAccont"));
                return;
            }
        }
Exemplo n.º 25
0
        private void backgroundWorkerFormLoad_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e)
        {
            CmbServer = Operation_FJ.BuildCombox(mServerInfo, CmbServer);

            LblUser.Text = "";
            //PnlInput.Visible = true;
            GrdList.DataSource = null;
            PnlPage.Visible    = false;
            tmp_ClientEvent    = m_ClientEvent.GetSocket(m_ClientEvent, Operation_FJ.GetItemAddr(mServerInfo, CmbServer.Text));
        }
Exemplo n.º 26
0
        private void backgroundWorkerActiveCode_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e)
        {
            BtnSearch.Enabled             = true;
            CEnum.Message_Body[,] mResult = (CEnum.Message_Body[, ])e.Result;
            if (mResult[0, 0].eName == CEnum.TagName.ERROR_Msg)
            {
                MessageBox.Show(mResult[0, 0].oContent.ToString());
                return;
            }

            Operation_FJ.BuildDataTable(this.m_ClientEvent, mResult, RoleInfoView, out iPageCount);
        }
        private void backgroundWorkerSearch_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e)
        {
            this.BtnSearch.Enabled        = true;
            this.Cursor                   = Cursors.Default;
            CEnum.Message_Body[,] mResult = (CEnum.Message_Body[, ])e.Result;
            if (mResult[0, 0].eName == CEnum.TagName.ERROR_Msg)
            {
                MessageBox.Show(mResult[0, 0].oContent.ToString());
                return;
            }

            Operation_FJ.BuildDataTable(this.m_ClientEvent, mResult, GrdItemResult, out iPageCount);
        }
Exemplo n.º 28
0
        private void btnSearchLog_Click(object sender, EventArgs e)
        {
            if (this.TxtItemName.Text == "" || this.TxtItemName.Text == null)
            {
                MessageBox.Show(config.ReadConfigValue("MFj", "FB_Code_MsgInputItemName"));
                return;
            }


            CEnum.Message_Body[,] mResult = null;
            CEnum.Message_Body[] mContent = new CEnum.Message_Body[6];

            mContent[0].eName    = CEnum.TagName.FJ_UserNick;
            mContent[0].eTag     = CEnum.TagFormat.TLV_STRING;
            mContent[0].oContent = TxtCharinfo.Text.Trim();

            mContent[1].eName    = CEnum.TagName.FJ_ServerIP;
            mContent[1].eTag     = CEnum.TagFormat.TLV_STRING;
            mContent[1].oContent = Operation_FJ.GetItemAddr(mServerInfo, CmbServer.Text);

            mContent[2].eName    = CEnum.TagName.FJ_ItemName;
            mContent[2].eTag     = CEnum.TagFormat.TLV_STRING;
            mContent[2].oContent = this.TxtItemName.Text.ToString();

            mContent[3].eName    = CEnum.TagName.FJ_Type;
            mContent[3].eTag     = CEnum.TagFormat.TLV_INTEGER;
            mContent[3].oContent = Operation_FJ.GetItemType(mType, this.CmbType.Text.ToString());

            mContent[4].eName    = CEnum.TagName.FJ_StartTime;//时间段开始时间
            mContent[4].eTag     = CEnum.TagFormat.TLV_DATE;
            mContent[4].oContent = Convert.ToDateTime(this.dateTimePickerTimeFrom.Value.ToLongDateString());

            mContent[5].eName    = CEnum.TagName.FJ_EndTime;
            mContent[5].eTag     = CEnum.TagFormat.TLV_DATE;
            mContent[5].oContent = Convert.ToDateTime(this.dateTimePickerTimeTo.Value.ToLongDateString());

            lock (typeof(C_Event.CSocketEvent))
            {
                mResult = Operation_FJ.GetResult(tmp_ClientEvent, CEnum.ServiceKey.FJ_ItemLog_Query, mContent);
            }
            if (mResult[0, 0].eName == CEnum.TagName.ERROR_Msg)
            {
                MessageBox.Show(mResult[0, 0].oContent.ToString());
                return;
            }
            else
            {
                logInfoView.DataSource = null;
                Operation_FJ.BuildDataTableItemAdd(this.m_ClientEvent, mResult, logInfoView, out iPageCount);
            }
        }
        private void BtnQueryMap_Click(object sender, EventArgs e)
        {
            try
            {
                if (txtUserID.Text.Trim().Length <= 0)
                {
                    return;
                }
                if (txtCharname.Text.Trim().Length <= 0)
                {
                    return;
                }

                //float a = float.Parse(txtX.Text);
                //float b = float.Parse(txtY.Text);

                CEnum.Message_Body[] mContent = new CEnum.Message_Body[2];

                mContent[0].eName    = CEnum.TagName.FJ_XPosition;
                mContent[0].eTag     = CEnum.TagFormat.TLV_STRING;
                mContent[0].oContent = "";

                mContent[1].eName    = CEnum.TagName.FJ_YPosition;
                mContent[1].eTag     = CEnum.TagFormat.TLV_STRING;
                mContent[1].oContent = "";


                lock (typeof(C_Event.CSocketEvent))
                {
                    AreaResult = Operation_FJ.GetResult(tmp_ClientEvent, CEnum.ServiceKey.FJ_MAP_Query, mContent);
                }

                if (AreaResult[0, 0].eName == CEnum.TagName.ERROR_Msg)
                {
                    MessageBox.Show(AreaResult[0, 0].oContent.ToString());
                    return;
                }
                else if (AreaResult[0, 0].eName == CEnum.TagName.FJ_Map)
                {
                    //txtMap.Text = mResult[0, 0].oContent.ToString();

                    txtMap = Operation_FJ.BuildAreaCombox(AreaResult, txtMap);

                    bFirst = true;
                }
            }
            catch
            {
                MessageBox.Show("坐标值有误");
            }
        }
Exemplo n.º 30
0
        private void TbcResult_SelectedIndexChanged(object sender, EventArgs e)
        {
            if (TbcResult.SelectedIndex == 1)
            {
                this.TxtCharinfo.Text = userAccount;
                tmp_ClientEvent       = m_ClientEvent.GetSocket(m_ClientEvent, Operation_FJ.GetItemAddr(mServerInfo, CmbServer.Text));

                CEnum.Message_Body[] mItemSubClass = new CEnum.Message_Body[1];
                mItemSubClass[0].eName    = CEnum.TagName.FJ_ServerIP;
                mItemSubClass[0].eTag     = CEnum.TagFormat.TLV_STRING;
                mItemSubClass[0].oContent = Operation_FJ.GetItemAddr(mServerInfo, CmbServer.Text);

                this.backgroundWorkerType.RunWorkerAsync(mItemSubClass);
            }
        }