Results 1 to 4 of 4

Thread: Book Mark?

  1. #1

    Thread Starter
    New Member
    Join Date
    Mar 2002
    Location
    Pakistan
    Posts
    2

    Exclamation Book Mark?

    Hi,
    I am accessing record from my database and display them in a treeview control and when click on the child node of treeview then display it's description in a richtextbox.
    I want to place book mark on child nodes, so that through bookmark i display it's description.
    When click on the BookMark button then it show the past bookmarks in a window and user can also place new bookmark.
    i mean like this:
    bookmark = parent.child.Description
    Please help me.
    thanks.


  2. #2
    Member FaRd0wN's Avatar
    Join Date
    Mar 2002
    Posts
    32
    by place a bookmark... do you mean to also add the description or just provide a way that people can quickly jump back to that child in the treeview?
    vBchode enabled

  3. #3

    Thread Starter
    New Member
    Join Date
    Mar 2002
    Location
    Pakistan
    Posts
    2

    Re: Book Mark

    No need for description, just put the track of the bookmark.
    and yes provide a way that people can quickly jump back to that child in the treeview

  4. #4
    Member FaRd0wN's Avatar
    Join Date
    Mar 2002
    Posts
    32
    does this help at all?
    the following works if the data set stays constant. but if it doesnt then you would have to take the fullpath as a string, grab the parts and trace it along the treeview. hope some of this is helpful.

    VB Code:
    1. Private Sub TreeView1_NodeClick(ByVal Node As ComctlLib.Node)
    2.     ' just a visual path, you might want it for IDing a bookmark
    3.     'List1.AddItem Node.FullPath
    4.     ' the actual index of a node from treeview
    5.     List1.AddItem Node.Index
    6. End Sub
    7.  
    8. Private Sub List1_Click()
    9.     ' variable is the index to bookmarked node
    10.     ' i didn't want to write out a function to
    11.     ' find out which item was clicked
    12.     Dim lngBooked As Long
    13.     lngBooked = 0
    14.     TreeView1.Nodes(Val(List1.List(lngBooked))).Selected = True
    15. End Sub
    vBchode enabled

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width