*First a static file with a field to remember the tree node: LAST_NODE C(2) *When you add the field, edit or replace LAST_NODE WITH "1_" *Then you have a last selected node key memeory variable. public ucLastNodeKey *Assuming the static file is open ucLastNodeKey=MySysDBF.LAST_NODE *in your treeview init event *add treeview nodes first this.tag=[dummy] this.nodeclick(this.Nodes(ucLastNodeKey)) *in your treeview NodeClick(Node) if node.key#this.tag && Not a re-click this.hideselection=.f. node.selected=.t. store node.key to ucLastNodeKey,this.tag * Go run menu operation else * Ignore - no change endif * In your app close event replace mySysDBF.LAST_NODE with ucLastNodeKey