Hi Rodd,
>I've built a very similar class structure ... one in which an "collection" object has an items() method that returns the object that it stores; but I'm not able to access the properties and methods of the returned object in the above manner. Instead, I'm forced to do this:
>
>oItem = oFolder.Items(1)
>oItem.subject = "This is a test"
>
>What can I do to my classes to enable the kind of "inline" syntax that I am able to use with the Outlook object?
- Add a property called oItem[1] to your class.
- Add an oItem_Access method
- In the access method your receiving the array index as a parameter
- Use this value to find the object reference you want and return it
- or -
- simply store your item references in the oItem property array
HTH,
Armin