Пример #1
0
        /// <summary>
        /// 设置dgv值
        /// </summary>
        /// <param name="dgv"></param>
        /// <param name="tm"></param>
        /// <param name="row"></param>
        public static void SetDgvValue(DataGridView dgv, DwdTendencyModel dwd1, DwdTendencyModel dwd2, int row)
        {
            dgv[1, row].Value = dwd1.Big.ToString() + "|" + dwd2.Big.ToString();     //大
            dgv[2, row].Value = dwd1.Small.ToString() + "|" + dwd2.Small.ToString(); //小
            dgv[3, row].Value = dwd1.Big.ToString() + "|" + dwd2.Small.ToString();   //大小
            dgv[4, row].Value = dwd1.Small.ToString() + "|" + dwd2.Big.ToString();   //小大
            dgv[5, row].Value = "";

            dgv[6, row].Value  = dwd1.Odd.ToString() + "|" + dwd2.Odd.ToString();   //奇
            dgv[7, row].Value  = dwd1.Pair.ToString() + "|" + dwd2.Pair.ToString(); //偶
            dgv[8, row].Value  = dwd1.Odd.ToString() + "|" + dwd2.Pair.ToString();  //奇偶
            dgv[9, row].Value  = dwd1.Pair.ToString() + "|" + dwd2.Odd.ToString();  //偶奇
            dgv[10, row].Value = "-";                                               //重
            dgv[11, row].Value = "趋势";
            dgv[12, row].Value = "-";

            for (int i = 1; i < 10; i++)
            {
                if (dgv[i, row].Value != null && dgv[i, row].Value.ToString() == "0|0")
                {
                    dgv.Rows[row].Cells[i].Style.Font      = new Font(DataGridView.DefaultFont, FontStyle.Bold);
                    dgv.Rows[row].Cells[i].Style.Font      = new Font("Tahoma", 13);
                    dgv.Rows[row].Cells[i].Style.BackColor = Color.LightGray;
                }
            }
        }
Пример #2
0
        private void initLabel()
        {
            if (Lottery.Lt_Lotterys.Count > 0)
            {
                //本次开奖号码
                LotteryModel lm = Lottery.Lt_Lotterys[0];
                this.lbl1.Text = lm.num1.ToString();
                this.lbl2.Text = lm.num2.ToString();
                this.lbl3.Text = lm.num3.ToString();
                this.lbl4.Text = lm.num4.ToString();
                this.lbl5.Text = lm.num5.ToString();
            }

            if (Tendency.Lt_Tendencys.Count > 0)
            {
                //本次未开奖走势
                TendencyModel tm = Tendency.CurrTendency;
                this.lblBig.Text      = tm.Big.ToString();
                this.lblBigSmall.Text = tm.BigSmall.ToString();
                this.lblSmallBig.Text = tm.SmallBig.ToString();
                this.lblSmall.Text    = tm.Small.ToString();

                this.lblOdd.Text     = tm.Odd.ToString();
                this.lblOddPair.Text = tm.OddPair.ToString();
                this.lblPairOdd.Text = tm.PairOdd.ToString();
                this.lblPair.Text    = tm.Pair.ToString();

                this.lblDbl.Text = tm.Dbl.ToString();
            }

            if (DwdTendency.Lt_Dwd.Count > 0)
            {
                DwdTendencyModel dtm1 = null;
                DwdTendencyModel dtm2 = null;

                //本次定位胆未开奖走势
                if (EnumStyle == Model.EnumStyle.后二)
                {
                    dtm1 = DwdTendency.GetCurrentDwdTendency(4);
                    dtm2 = DwdTendency.GetCurrentDwdTendency(5);
                }
                //本次定位胆未开奖走势
                else if (EnumStyle == Model.EnumStyle.前二)
                {
                    dtm1 = DwdTendency.GetCurrentDwdTendency(1);
                    dtm2 = DwdTendency.GetCurrentDwdTendency(2);
                }

                this.lblDwdBig.Text   = dtm1.Big.ToString() + dtm2.Big.ToString();
                this.lblDwdSmall.Text = dtm1.Small.ToString() + dtm2.Small.ToString();

                this.lblDwdBigSmall.Text = dtm1.Big.ToString() + dtm2.Small.ToString();
                this.lblDwdSmallBig.Text = dtm1.Small.ToString() + dtm2.Big.ToString();

                this.lblDwdOdd.Text     = dtm1.Odd.ToString() + dtm2.Odd.ToString();
                this.lblDwdPair.Text    = dtm1.Pair.ToString() + dtm2.Pair.ToString();
                this.lblDwdOddPair.Text = dtm1.Odd.ToString() + dtm2.Pair.ToString();
                this.lblDwdPairOdd.Text = dtm1.Pair.ToString() + dtm2.Odd.ToString();
            }
        }
Пример #3
0
        /// <summary>
        /// 当前走势
        /// </summary>
        public static DwdTendencyModel GetCurrentDwdTendency(int digitNum)
        {
            DwdTendencyModel dtm = null;
            var vs = Lt_Dwd.Where(l => l.type == digitNum).ToList();

            if (vs.Count > 0)
            {
                dtm = vs[vs.Count - 1];
            }
            return(dtm);
        }
Пример #4
0
        /// <summary>
        /// 定位胆开奖趋势分析
        /// </summary>
        private void analyzeDwdTendency(Lottery lottery, DwdTendency dwdTendency, int index)
        {
            dwdTendency.ClearDwdTendencys();//清空记录
            DwdTendencyModel tm;

            AnalyzeDwdTendency at = new AnalyzeDwdTendency();

            for (int i = lottery.Lt_Lotterys.Count - 1; i >= 0; i--)
            {
                tm       = new DwdTendencyModel();
                tm.Big   = at.BigNum(lottery.Lt_Lotterys, i, index);       //大
                tm.Small = at.SmallNum(lottery.Lt_Lotterys, i, index);     //小

                tm.Odd  = at.OddPairNum(lottery.Lt_Lotterys, i, index, 1); //奇
                tm.Pair = at.OddPairNum(lottery.Lt_Lotterys, i, index, 0); //偶
                dwdTendency.AddDwdTendency(tm);                            //添加定位胆趋势记录
            }
        }
Пример #5
0
        /// <summary>
        /// 定位胆开奖趋势分析
        /// </summary>
        private void analyzeDwdTendency(Lottery lottery, DwdTendency dwdTendency, int index)
        {
            dwdTendency.ClearDwdTendencys();//清空记录
            DwdTendencyModel tm;

            AnalyzeDwdTendency at = new AnalyzeDwdTendency();

            for (int i = lottery.Lt_Lotterys.Count - 1; i >= 0; i--)
            {
                tm         = new DwdTendencyModel();
                tm.Lottery = lottery.Lt_Lotterys[i].Lottery;
                tm.Big     = at.BigNum(lottery.Lt_Lotterys, i, index);     //大
                tm.Small   = at.SmallNum(lottery.Lt_Lotterys, i, index);   //小

                tm.Odd  = at.OddPairNum(lottery.Lt_Lotterys, i, index, 1); //奇
                tm.Pair = at.OddPairNum(lottery.Lt_Lotterys, i, index, 0); //偶

                tm.Sno   = (lottery.Lt_Lotterys[i].Sno.ToString() + "期").PadLeft(5, '0');
                tm.Dtime = lottery.Lt_Lotterys[i].Dtime;

                dwdTendency.AddDwdTendency(tm);//添加定位胆趋势记录
            }
        }
Пример #6
0
        /// <summary>
        /// 定位胆开奖趋势分析
        /// </summary>
        private void analyzeDwdTendency()
        {
            DwdTendency.ClearDwdTendencys();//清空记录
            DwdTendencyModel tm;

            DwdTendency dt = new DwdTendency();

            for (int k = 1; k <= 5; k++)
            {
                for (int i = Lottery.Lt_Lotterys.Count - 1; i >= 0; i--)
                {
                    tm       = new DwdTendencyModel();
                    tm.Big   = dt.BigNum(i, k);       //大
                    tm.Small = dt.SmallNum(i, k);     //小

                    tm.Odd  = dt.OddPairNum(i, 1, k); //奇
                    tm.Pair = dt.OddPairNum(i, 0, k); //偶
                    tm.type = k;                      //类型

                    DwdTendency.AddDwdTendency(tm);   //添加定位胆趋势记录
                }
            }
        }
Пример #7
0
 /// <summary>
 /// 新增趋势记录
 /// </summary>
 /// <param name="lottery"></param>
 public void AddDwdTendency(DwdTendencyModel tm)
 {
     Lt_Dwds.Add(tm);
 }