Re: Emptying simplelist?



Artūras ?lajus said:
Hi

I want to make simplelist look empty in treeview. How do i do that?
  delete $UserList->{'data'}; don't work.

@{$UserList->{'data'}} = ();
that should do the trick. it sets the list to empty, thus showing nothing.
have a look at simplelist.pl for examples of most of the things you can do
with a SimpleList.

what you were doing above, the delete, would remove the key 'data' from the
$UserList hash/object which is not what you wanted and would likely render the
SimpleList broken and of no more use.

-rm



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]