I'm getting this error all of a sudden in my designer.
If I remove this line, it runs just fine, but then a panel in my app doesn't show up.
this.formMEMain_Fill_Panel.Controls.Add(this.formMEMain_Fill_Panel.ClientArea);
Hello Sean,
In order to fix this issue, what you would need to do is replacing the lines of code that contain this:
this.formMEMain_Fill_Panel.Controls.Add(…)
With the following line:
this.formMEMain_Fill_Panel.ClientArea.Controls.Add(…)
Afterwards, the solution should be cleaned and rebuilt and the issue should be resolved.
Please let me know if you need any further assistance.
Regards, Ivan Kitanov
I changed the code, cleaned, and rebuilt.
Now I get this:
Yeah, the designer did this. It used to work just fine, then I upgraded to the latest version and switched to VS2022 and it broke. For now I just removed it even though I've got a panel missing now.
Thx.
If the line that adds the ClientArea panel to the Controls collection was automatically added, this normally indicates that the Infragistics Designer assembly was not found. Our designer assembly has a CodeDomSerializer that prevents that specific line of code from being included in the designer generated code. Make sure the version of the product installed on the machine matches the version of the assemblies referenced in the project. It is safe to delete that line of code from InitializeComponents().
I noticed that in your initial post you are trying to add formMEMain_Fill_Panel.ClientArea to the panel itself and this is causing the circular reference. The ClientArea property gets the control which makes up the client area of the UltraPanel and hosts all child controls, but it already a part of the UltraPanel so there is no need of adding it.
What you will need to do instead is adding the controls directly to the ClientArea. Similarly to the code below:
this.formMEMain_Fill_Panel.ClientArea.Controls.Add(this.textBox1);
this.formMEMain_Fill_Panel.ClientArea.Controls.Add(this.ultraGrid1);
Please let me know if you have any questions or concerns.