/// <summary> /// 同步上传时,KbaseName 发生变化时 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void txbKbasename_EditValueChanged(object sender, EventArgs e) { var tableName = txbKbasename.Text; if (KbaseHelper.GetCols(tableName).Count == 0) labOK.Text = string.Empty; else labOK.Text = "√"; }
/// <summary> /// Kbase导出数据,Kbase表名发生变化时 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void txbTable_EditValueChanged(object sender, EventArgs e) { var tableName = txbTable.Text; var Cols = KbaseHelper.GetCols(tableName); if (Cols == null || Cols.Count == 0) return; List<dynamic> Datas = new List<dynamic>(); foreach (var item in Cols) { dynamic data = new ExpandoObject(); data.KbaseB = item; data.KbaseE = string.Empty; Datas.Add(data); } repositoryItemComboBox2.Items.AddRange(new List<string> { "文件名", "正文", "题名", "关键词", "摘要", "主题" }); gridKbase.DataSource = Datas; }