コード例 #1
0
        /// <summary>
        /// 数据绑定
        /// </summary>
        private void DataBind()
        {
            //下方总窗体数据绑定
            InterviewDataGridView.DataSource = interviewBll.GetAllInterviewList();

            //出版社数据绑定
            BindingSource bs_PublishingHouse = new BindingSource();

            bs_PublishingHouse.DataSource         = utilBll.GetPublishingHouseNames();
            PublishingHouseComboBox.DataSource    = bs_PublishingHouse;
            PublishingHouseComboBox.ValueMember   = "Key";
            PublishingHouseComboBox.DisplayMember = "Value";
        }
コード例 #2
0
        /// <summary>
        /// 数据绑定
        /// </summary>
        private void DataBind()
        {
            //上方总窗体数据绑定
            InterviewDataGridView.DataSource = interviewBll.GetAllInterviewList();
            //下方总窗体数据绑定
            OrderDataGridView.DataSource = interviewBll.GetAllPurchaseOrders();

            //出版社数据绑定
            BindingSource bs_PublishingHouse = new BindingSource();

            bs_PublishingHouse.DataSource         = utilBll.GetPublishingHouseNames();
            publishingHouseComboBox.DataSource    = bs_PublishingHouse;
            publishingHouseComboBox.ValueMember   = "Key";
            publishingHouseComboBox.DisplayMember = "Value";

            SubscriberTextBox.Text = AdminForm.admin.Number;
        }