Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Treeview .Object property weirdness
Message
From
25/09/2002 08:07:46
 
General information
Forum:
Visual FoxPro
Category:
ActiveX controls in VFP
Miscellaneous
Thread ID:
00703871
Message ID:
00704151
Views:
21
Actually - we traced it to something that HAS to be a bug - namely a "for each loop"
When treeview form is instatiated oTree.object correctly references the treeview object.
Then we called a method that did a
for each loNode in oTree.Nodes
do something
endfor
after running that - oTree.object references the first node object! We fixed it by simply changing to
for i = 1 to oTree.Nodes.Count
loNode = oTree.Nodes(i)
do something
endfor
very strange ....

Thanks!

>Ken,
>
>Can you show the code that is actually erroring out?
>
>The only time I ever use .Object is to make sure the right property gets accessed for conflicts with VFP PEMs.
>
>
oTree.object.XYZ =
>? oTree.object.ASD
>
>I don't know if you can actually do something like
>
>
oX = oTree.object
>oX.ABC =
>
>>I am having a strange situation where if 'oTree' is a reference to my treeview control, 'oTree.object' is returning a reference to the first NODE object in the treeview rather than the treeview object itself.
>>
>>Any ideas why/how this could be happening?
Ken B. Matson
GCom2 Solutions
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform