We help IT Professionals succeed at work.

VB style collections in attributed ATL

cmain
cmain asked
on
265 Views
Last Modified: 2013-11-20
Hi,

I am trying to implement a simple collection of words, like the MSDN sample that contains a list of words.
I need to implement count, item, _NewEnum etc using an STL collection to implement _NewEnum.

I am struggling to instantiate my collection class inside the property that returns it.

What I really require from someone is a simple collection sample that returns an enumeration that is written using the new attributed ATL.
Is it not possible to use attributed ATL and return a simple collection object?

Regards
Craig.
Comment
Watch Question

Commented:
This one is on us!
(Get your first solution completely free - no credit card required)
UNLOCK SOLUTION

Author

Commented:
Hi,

Both these samples use the old style ATL.
CWords is not attributed, it uses the old template libraries, and the project at codeguru is VC6.00

Regards

Author

Commented:
The following code

      CComObject<IFiles>* pFiles1;
      CComObject<IFiles>::CreateInstance(&pFiles1);

Issues the following result with my attributed collection class.
FinalRelease identifier not found, even with argument-dependent lookup

Commented:
IMHO
attributed DLL is the kind of evil :-) The simplest way to get trouble :-)
May be you recreate your object without attributed option set?

Commented:
IMHO
attributed ATL is the kind of evil :-) The simplest way to get trouble :-)
May be you recreate your object without attributed option set?
Unlock the solution to this question.
Join our community and discover your potential

Experts Exchange is the only place where you can interact directly with leading experts in the technology field. Become a member today and access the collective knowledge of thousands of technology experts.

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.