Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Accessing Collection through another property
Message
From
13/08/2003 03:54:22
 
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00819334
Message ID:
00819707
Views:
8
Larry

This is what seems to be the problem (it is a COM DLL btw), I'll show you the code I'm executing and where it fails, NOTE: It DOES work using the class libaries directly from Fox, it's just the COM Object that it doesn't work on (and it doesn't error).
*COM Object
loList = CREATEOBJECT("COMPROJ.LISTOBJECT") && List Object is a wrapper class for Collection
loList.Add("Test", "001")
?loList.Item(1) && PASS
?loList.Item("001") && FAILS - RETURNS .T., which means that 001 returns 0 when GetKey issued by Item_Access
?loList.List.Item("001") && PASS - The List property is holding the collection, so I can access it fine directly
Hope that makes sense, it seems that outside the COM Class I can access the list fine, but internally the item_Access method is struggling and it is getting funny results when querying it's own properties!!!!

Any ideas?

Thanks
Kev
Previous
Reply
Map
View

Click here to load this message in the networking platform