Reputation: 285
I've got code in WinForms which i need to convert to WPF DevExpress.
I need to create LookUpEdit in code and add it to a created gridColumn.
The code in winforms:
var editor = (RepositoryItemLookUpEdit) gridControl.RepositoryItems.Add("LookUpEdit");
editor.DataSource = CreateList(query);
for (int i = 0; i < ... < ....Count; i++)
{
var columnInfo = new LookUpColumnInfo(parentTableColumns[i].Name)
{SortOrder = ColumnSortOrder.Ascending};
editor.Columns.Add(columnInfo);
}
editor.BestFitMode = BestFitMode.BestFitResizePopup;
gridColumn.ColumnEdit = editor;
gridColumn.FilterMode = ColumnFilterMode.DisplayText;
RepositoryItemLookUpEdit, LookUpColumnInfo does not exist in Xpf not winforms, how do i do exact things in DevExpress WPF ?
Upvotes: 0
Views: 4677
Reputation: 29
I was searching for almost the same thing and i found this link giving some information about my case . I added a sample project and the Dev express support edit it to help me implement the lookUpEdit in grid Column . the Solution is not perfect yet (for me ) but maybe your case is simpler and this is you solution .
the link to dev express page Grid and LookupEditSettings
Upvotes: 2