This is what I think you need (assuming the name of
your LookupEdit is lookupEdit1):
[DefaultValue((string)null),
#if
DXWhidbey
AttributeProvider(typeof(IListSource))]
#else
TypeConverter("System.Windows.Forms.Design.DataSourceConverter,
System.Design")]
#endif
public
object DataSource {
get { return
lookupEdit1.DataSource; }
set {
lookupEdit1.DataSource = value;
}
}
[DefaultValue((string)null), Editor(ControlConstants.DataMemberEditor, typeof(System.Drawing.Design.UITypeEditor))]
public string DataMember {
get { return
lookupEdit1.DataMember; }
set { lookupEdit1.DataMember = value; }
}
I want to create a new control which is a composite of other
controls. I want my new control to contain a LookUpEditor and one or
more LabelControls that will show the details of the record that the user
selected.
What container should I use to hold the controls (XtraUserControl?)?
How do I create the properties that are needed to set dataSource,
displayMember, editValue and valueMember.
Are there any examples of what I am trying to do?
http://community.devexpress.com//forums/p/68090/231649.aspx#231649