Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Desperately seeking help with Tree Control (Active-X)
Message
De
13/08/1998 17:30:52
Renato De Giovanni
Via Fractal Information Systems
São Paulo, Brésil
 
 
À
13/08/1998 14:59:49
Information générale
Forum:
Visual FoxPro
Catégorie:
Problèmes
Divers
Thread ID:
00126594
Message ID:
00126722
Vues:
20
>>Thanks for your answer !
>>
>>well, I'm still using version 5.00.3828 (february 28, 1997) as this was the newest thing I found on the MSDN (look for article Q167121).
>>
>>If I use HitTest it keeps returning an empty string ?!
>>
>>Further questions:
>>
>>1) Do you use Fox6 ???
>>
>>2) Can you use the TreeCtrl properties sheet to set things like fonts, mouse_icons, and ImageList ??? (I was able to do it, but with an older version ;-) seems that this stuff is not as backward compatible as it should be...)
>>
>>3) Does CreateDragImage work ?
>
>I finally got my HitTest to work. (Thanks again, Renato!) SYS(2333,0) was the answer to my problem.
>
>For HitTest, you have to convert the mouse coordinates from pixels to twips.
>
>HitTest also returns an object reference for the node it was on, not a character string.
>
>1) I have VFP 6 beta from DevCon and from MSDN. Haven't had much time to play with it, though.
>
>2) The fonts stuff can be accessed through code. this.TreeView.Fonts.Name, .Size, .Bold, etc.
> ImageList can be accessed through code also. In TreeView.Init:
>
>this.object.imagelist = this.parent.imagelist.object
>
>You don't need their property sheet, it just makes life easier (when it works).
>
>Yes, they have broken this many times, in many ways. It does seem to work in VFP6 though.
>
>3) Haven't tried to work with CreateDragImage. It IS on my "To-Do" list.

Just adding more comments on this, I´m working with version 5.00.3714 and also couldn´t get CreateDragImage to work. Hope it´s fixed in the newest version of vfp!

About the HitTest method, besides being in twips, the coordinates should be related to the treeview borders. That´s ok when you´re using it in MouseDown or MouseMove events. But DragOver, DragDrop, MCOL or MROW give you coordinates related to the Form borders; so there´s more work to do in this case.

If you´re needing to implement drag&drop into the treeview, there´s already a class called ndragger which can help with the task. It´s available in the files section.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform