RepositoryItemSearchLookUpEdit 的问题
DataTable myds = new DataTable();
myds=new Bllmedcoding().GetAllList().Tables[0];
myds.Columns["medinfoid"].Caption = "编码";
myds.Columns["medname"].Caption = "名称";
myds.Columns["specs"].Caption = "规格";
myds.Columns["unit"].Caption = "单位";
myds.Columns["pym"].Caption = "拼音码";
RepositoryItemSearchLookUpEdit repositoryMedinfoid = new RepositoryItemSearchLookUpEdit();
repositoryMedinfoid.DataSource =myds ;
repositoryMedinfoid.DisplayMember = "medname";
repositoryMedinfoid.ValueMember = "medinfoid";
repositoryMedinfoid.CloseUpKey = new DevExpress.Utils.KeyShortcut(Keys.Space);
repositoryMedinfoid.PopupFormSize = new Size(1000, 500);
this.gridControl1.RepositoryItems.Add(repositoryMedinfoid);
this.gridView1.Columns["medinfoid"].ColumnEdit = repositoryMedinfoid;
想知道:1、gridView可以用其Columns集合属性为每个字段赋中文名,RepositoryItemSearchLookUpEdit有没有相关的字段属性,另外其字段的visible属性有没有对应的设置。
2、gridView和此处RepositoryItemSearchLookUpEdit的列宽如何自定义设置。
--------------------编程问答-------------------- 除 --------------------编程问答-------------------- 纠结了很久的问题,终于发现了解决办法
GridColumn column = searchLookUpEdit1.Properties.View.Columns.AddField("CustomerID");
column.Visible = true;
column = searchLookUpEdit1.Properties.View.Columns.AddField("Date");
column.Visible = true;
补充:.NET技术 , C#