Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 169
  • Last Modified:

Could someone assist me with this code?

Hi again.  I am still copying this material from a textbook, but have again met with an obstacle.

After copying the form and class modules, when I run it, I get a "User-defined type not defined" on the following line (for DataSource):

'*****Property Procedures*****

Public Property Get Insurance() As DataSource
    'Expose the data source to bind to the DataCombo box
    Set Insurance = mDataService
End Property

Can anyone help me locate the problem?
  • 2
1 Solution
It looks like you may need to make a reference to the appropriate data access component.  Try this:

Go to Project  >  References and make a reference to the data access component outlined in your book...

shawngilbertAuthor Commented:
The only references the text mentions are to Microsoft Data Binding Collection and Microsoft ActiveX Data Objects 2.0 Library
Although I have added a reference to Microsoft Data Source Interfaces and it gets beyond that point.
Now I need to determine why it's failing from here.

Thank you for the assistance.

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now