Link to home
Start Free TrialLog in
Avatar of tdukek
tdukek

asked on

VS 2005 Designer error loading form with UserControl

I have UserControls which contain BindingSource(s) bound to dataset/tables. Designer loads the user controls fine. Have had a random problem with the Designer getting an error when trying to load form(s) containing these UserControls. Errors are always triggered within the UserControl's InitializeComponent EndInit on the BindingSource such as below. Application runs fine.

Error
=====

DataMember property 'ProposalJobs' cannot be found on the DataSource.
Hide    

at System.Windows.Forms.ListBindingHelper.GetList(Object dataSource, String dataMember)
at System.Windows.Forms.BindingSource.ResetList()
at System.Windows.Forms.BindingSource.EnsureInnerList()
at System.Windows.Forms.BindingSource.System.ComponentModel.ISupportInitialize.EndInit()
at CFSUIElements.CFSProposalPanel.InitializeComponent() in C:\Documents and Settings\Teresa\My Documents\Visual Studio 2005\Projects\CFS2\JobsLibrary\JobsLibrary\CFSUIElements\CFSProposalPanel.Designer.vb:line 1437
at CFSUIElements.CFSProposalPanel..ctor()
Avatar of tdukek
tdukek

ASKER

Not quite.
The first reference is for the case where a bindingsource is used as a datasource for another. I'm not doing that here. I'm simply binding to a datatable within a dataset.
The second reference seems specific to a known bug (3rd reference) for using 2 datagridview(s) which I am not doing either. The error is the same though. I'm thinking it is some kind of bug with Visual Designer but would be very interested if anyone has come up with a work around once the situation arises.
ASKER CERTIFIED SOLUTION
Avatar of kaylanreilor
kaylanreilor
Flag of Luxembourg image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of tdukek

ASKER

I'm hoping to retain design time databinding. But, I guess I can always just add my UserControls programmatically to my main form if I have to.
Avatar of tdukek

ASKER

Thanks for your feedback.