Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Primary key problem
Message
From
26/10/2001 15:18:34
 
 
To
26/10/2001 14:00:57
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00573665
Message ID:
00573896
Views:
25
Thank you Cetin. Thats an excellent article you wrote. I will be using a lot as this is my first crack at the Treeview control.

>Instead of node index directly use the node key. It's typically is your character primary key. ie: nodes(nIndex) and nodes('00004') both work. You don't need to follow indexes. Table looks like :
>
>
>NodeKey       ParentKey    NodeText
>------------- ---------    --------
>charles_mary               Root parents
>sue           Charles_Mary Sue is single
>fred_beth     Charles_Mary Fred and Beth were married in 1997
>
>NodeKey is char and your table's PKId.
>nodes('sue') work whatever its current index is. Check UT magazine June issue for sample with testdata and folders (with code).
>Cetin
>
>>Hi,
>>
>>Thanks for your reply. I realized the way I am doing this will not work and in the long run give more troubles. Do you know of a good way I could 'relate' the treeview to a table? For example, if I click on a leaf or node how can I determine which record in my table this corresponds to. I was using the node.index before but I don't think this will work.
>>
>>Thanks,
>>Chris
Previous
Reply
Map
View

Click here to load this message in the networking platform