PHP-GTK2 Cookbook Forum
Welcome, Guest
Please Login or Register.    Lost Password?
Re:Point to the last row of data (1 viewing) (1) Guest
Go to bottom Post Reply Favoured: 0
TOPIC: Re:Point to the last row of data
#909
edryan (User)
Junior Boarder
Posts: 21
graphgraph
User Offline Click here to see the profile of this user
Point to the last row of data 3 Months ago Karma: 0  
hi,

I have a treeview and i want the scrollbar to point to the last row after I add a new record.

i just want to automatically scroll down the scrollbar to the last record after the the add operation.

i would be glad if some scripts are available.tnx!
 
  The administrator has disabled public write access.
#912
kksou (Admin)
Admin
Posts: 443
graph
User Online Now Click here to see the profile of this user
Re:Point to the last row of data 3 Months ago Karma: 8  
Please refer to the following sample code:

Sample Code 507: How to highlight and scroll to a particular row in treeview using row ID?

Try to understand the sample code first.

Then for your case, do something like:
Code:
$n = $model->iter_n_children(NULL);
$view->scroll_to_cell($n);
    It should scroll to the last row of the treeview.
      Regards,
        /kksou
         
          The administrator has disabled public write access.
        Go to top Post Reply
        Powered by FireBoardget the latest posts directly to your desktop

        Blog - Forum - Privacy Policy - Contact Us
        Copyright © 2006-2009. kksou.com. All Rights Reserved