none
Build failure after binding ListBox to DataSource RRS feed

  • Question

  • I have a Forms project with three forms, Form1,Form2,Form3.  I set a DataSource for a ListBox in Form3, a column in an sql server table, set the DisplayMember to the column name.  Build fails

    Data type 'ColumnName' does not exist in the type Form1

    Data type ColumnNameTableAdapters' does not exist in the type Form1.

    These errors repeat once.  No idea why the build errors say Form1 if the ListBox is in Form3.  

    Tuesday, August 27, 2019 5:53 PM

Answers

  • Problem was one of my forms (classes) had the same name as my project (namespace).  Changed the form name, build successful with DataSource.
    Tuesday, August 27, 2019 7:29 PM

All replies

  • Problem was one of my forms (classes) had the same name as my project (namespace).  Changed the form name, build successful with DataSource.
    Tuesday, August 27, 2019 7:29 PM
  • Hi RichardDunneBSc,

    Welcome to the MSDN forum.

    We are glad to hear that your issue solved.If you have any other issues about this aspect, please feel free to let us know. We are willing to help you further.

    Thanks for your understanding.

    Best Regards,

    Perry


    MSDN Community Support Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com

    Wednesday, August 28, 2019 3:14 AM