[DevExpress Support Team: CLONED FROM T288096: DataLayoutControl throws ArgumentException when bound to the XPCollection]
No properties are listed in the xpcollection and the options on the datalayoutcntrol are not set.
This is the call stack with the latest versions
mscorlib.dll!System.Array.Resize<System.Reflection.PropertyInfo>(ref System.Reflection.PropertyInfo[] array, int newSize) Unknown
mscorlib.dll!System.RuntimeType.ListBuilder<System.Reflection.PropertyInfo>.ToArray() Unknown
mscorlib.dll!System.RuntimeType.GetProperties(System.Reflection.BindingFlags bindingAttr) Unknown
> DevExpress.XtraLayout.v15.1.dll!DevExpress.XtraDataLayout.LayoutElementsBindingInfoHelper.IsSimpleType(System.Collections.Hashtable dataTypeHashtable, System.Type dataType) Line 990 C#
DevExpress.XtraLayout.v15.1.dll!DevExpress.XtraDataLayout.LayoutElementsBindingInfoHelper.IsSimpleType.AnonymousMethod__8(System.Reflection.PropertyInfo p) Line 991 C#
System.Core.dll!System.Linq.Enumerable.Any<System.Reflection.PropertyInfo>(System.Collections.Generic.IEnumerable<System.Reflection.PropertyInfo> source, System.Func<System.Reflection.PropertyInfo, bool> predicate) Unknown
The last 3 lines just repeats undefinetely, and this is the exception
System.StackOverflowException was unhandled
HResult=-2147023895
Message=Exception of type 'System.StackOverflowException' was thrown.
InnerException:
C#//
// src (the XPCollection)
//
this.src.LoadingEnabled = false;
this.src.ObjectType = typeof(BlueCashNEXT.Data.Gestione.AttivitaSvolta);
this.src.ResolveSession += new DevExpress.Xpo.ResolveSessionEventHandler(this.src_ResolveSession);
//
// layoutControl
//
this.layoutControl.Controls.Add(this.OperatoreLookupEdit);
this.layoutControl.Controls.Add(this.AziendaLookupEdit);
this.layoutControl.Controls.Add(this.AttivitaLookupEdit);
this.layoutControl.Controls.Add(this.ClienteLookupEdit);
this.layoutControl.Controls.Add(this.ProgettoLookupEdit);
this.layoutControl.Controls.Add(this.DataDateEdit);
this.layoutControl.Controls.Add(this.DescrizioneMemoEdit);
this.layoutControl.Controls.Add(this.NoteMemoEdit);
this.layoutControl.Controls.Add(this.QuantitaSpinEdit);
this.layoutControl.Controls.Add(this.SospendiFatturazioneToggleSwitch);
this.layoutControl.Controls.Add(this.TariffaPersonalizzataSpinEdit);
this.layoutControl.Controls.Add(this.ReferenteComboBoxEdit);
this.layoutControl.DataSource = this.src;
this.layoutControl.Dock = System.Windows.Forms.DockStyle.Fill;
this.layoutControl.Location = new System.Drawing.Point(0, 24);
this.layoutControl.Name = "layoutControl";
this.layoutControl.OptionsPrint.AppearanceGroupCaption.BackColor = System.Drawing.Color.LightGray;
this.layoutControl.OptionsPrint.AppearanceGroupCaption.Font = new System.Drawing.Font("Tahoma", 10.25F);
this.layoutControl.OptionsPrint.AppearanceGroupCaption.Options.UseBackColor = true;
this.layoutControl.OptionsPrint.AppearanceGroupCaption.Options.UseFont = true;
this.layoutControl.OptionsPrint.AppearanceGroupCaption.Options.UseTextOptions = true;
this.layoutControl.OptionsPrint.AppearanceGroupCaption.TextOptions.HAlignment = DevExpress.Utils.HorzAlignment.Center;
this.layoutControl.OptionsPrint.AppearanceGroupCaption.TextOptions.VAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControl.OptionsPrint.AppearanceItemCaption.Options.UseTextOptions = true;
this.layoutControl.OptionsPrint.AppearanceItemCaption.TextOptions.HAlignment = DevExpress.Utils.HorzAlignment.Near;
this.layoutControl.OptionsPrint.AppearanceItemCaption.TextOptions.VAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControl.Root = this.Root;
this.layoutControl.Size = new System.Drawing.Size(602, 366);
this.layoutControl.TabIndex = 5;
this.layoutControl.Text = "dataLayoutControl1";