コード例 #1
0
ファイル: frmQuesChange.cs プロジェクト: kaiss78/hustoes
        public frmQuesChange(Problem problem)
        {
            InitializeComponent();
            InitCombText();

            this.Typecombo.SelectedIndex = 0;
            this.Diffcombo.SelectedIndex = 0;
            this.Textcombo.SelectedIndex = 0;

            if (problem != null)
            {
                int quesType = Convert.ToInt32(problem.type);
                this.Typecombo.SelectedIndex = quesType;
                this.scoreBox.Text = Convert.ToString(problem.score);
            }
            else
            {
                this.scoreBox.Text = "";
            }

            aList = (ListItem)this.Unitcombo.SelectedItem;
            pointWords = this.PcontentText.Text;
            theType = this.Typecombo.SelectedIndex;
            InitList(this.Typecombo.SelectedIndex, Convert.ToInt32(aList.key), Convert.ToInt32(bList.key), this.Diffcombo.SelectedIndex, pointWords, 1);
            this.Pagecombo.Items.Clear();
            InitCombPage(quesNum);
        }
コード例 #2
0
ファイル: frmQuesChange.cs プロジェクト: kaiss78/hustoes
 private void SearchBut_Click(object sender, EventArgs e)
 {
     aList = (ListItem)this.Unitcombo.SelectedItem;
     pointWords = this.PcontentText.Text;
     theType = this.Typecombo.SelectedIndex;
     InitList(this.Typecombo.SelectedIndex, Convert.ToInt32(aList.key), Convert.ToInt32(bList.key), this.Diffcombo.SelectedIndex, pointWords, 1);
     this.Pagecombo.Items.Clear();
     InitCombPage(quesNum);
 }