Ejemplo n.º 1
0
 private void tb_PointsBlue_Total_TextChanged(object sender, EventArgs e)
 {
     try
     {
         m_nMatch_Individual.PointsTotal_Blue = GVAR.Str2Int(tb_PointsBlue_Total.Text.Trim());
         m_nMatch_Individual.UpdateMatchResultPoints();
         UpdateControlFromDataBase();
     }
     catch (System.Exception ex)
     {
         Log.WriteLog("WR_Error", ex.Message);
     }
 }
Ejemplo n.º 2
0
        private void GetDataFillDataBase(string str)
        {
            try
            {
                string strStart = "Liaoning2013WR";

                if (!str.StartsWith(strStart))
                {
                    return;
                }

                string[] strSplit = str.Substring(strStart.Length).Split(',');


                string strMatchNo = strSplit[1];
                int    redScore   = GVAR.Str2Int(strSplit[9]);
                int    blueScore  = GVAR.Str2Int(strSplit[10]);

                int setNo = GVAR.Str2Int(strSplit[8]);


                if (GVAR.g_ManageDB.GetMatchSplitStatus(strMatchNo, setNo) == 110)
                {
                    return;
                }

                int currentPointsRed = GVAR.g_ManageDB.GetMatchSplitPoints(strMatchNo, setNo, 1);

                int currentPointsBlue = GVAR.g_ManageDB.GetMatchSplitPoints(strMatchNo, setNo, 2);

                //if(redScore>currentPointsRed)
                GVAR.g_ManageDB.WR_TS_UpdateDatabase(strMatchNo, setNo, 1, redScore);

                //if(blueScore>currentPointsBlue)
                GVAR.g_ManageDB.WR_TS_UpdateDatabase(strMatchNo, setNo, 2, blueScore);
            }
            catch (Exception ex)
            {
                Log.WriteLog("WR_Error", ex.Message);
            }
        }
Ejemplo n.º 3
0
        protected override void OnMgrEvent(object sender, OVRMgr2PluginEventArgs e)
        {
            switch (e.Type)
            {
            case OVRMgr2PluginEventType.emMatchSelected:
            {
                if (m_frmWRPlugin != null)
                {
                    m_frmWRPlugin.OnMsgFlushSelMatch(0, GVAR.Str2Int(e.Args.ToString()));
                    SetReportContext("MatchID", e.Args.ToString());
                }
                break;
            }

            case OVRMgr2PluginEventType.emRptContextQuery:
            {
                QueryReportContext(e.Args as OVRReportContextQueryArgs);
                break;
            }
            }
        }
Ejemplo n.º 4
0
 private void tb_ClassidicationPoints_Blue_TextChanged(object sender, EventArgs e)
 {
     m_nMatch_Individual.ClassidicationPoints_Blue = GVAR.Str2Int(tb_ClassidicationPoints_Blue.Text);
 }