コード例 #1
0
        private void backgroundWorker1_DoWork(object sender, DoWorkEventArgs e)
        {
            //decimal i = 0;
            //decimal _count = Convert.ToDecimal(this.QueryModel.ChildTableDict.Count);

            //foreach (MDModel_Table _ctable in this.QueryModel.ChildTableDict.Values)
            //{

            //        decimal _progress = i / _count * 100;
            //        int _ret = SinoSZQueryConfig.MetaDataFactroy.GetChildTableCountByKey(this.QueryModel.QueryModelName, _ctable.TableName, this.MainKeyID);
            //        if (_ret > 0)
            //        {
            //                MDQuery_ChildTableRowCount _item = new MDQuery_ChildTableRowCount(_ctable.TableName, _ret);
            //                this.backgroundWorker1.ReportProgress(Convert.ToInt32(_progress), _item);
            //        }
            //        i++;
            //}
            using (MetaDataQueryServiceClient _msc = new MetaDataQueryServiceClient())
            {
                this._childRowCountList = _msc.GetChildRowCountList(this.QueryModel.FullQueryModelName, this.MainKeyID).ToList <MDQuery_ChildTableRowCount>();
            }
        }