Forum: FXRuby FXTreeList clarification

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
4a08552837dcba90ea4159f26c9e989c?d=identicon&s=25 Teena Kingswell (kingswell)
on 2008-05-26 10:58
i'm pretty new to both ruby and fxruby, and im currently trying to work
my way through writing my first program but i've run into a bit of a
ditch trying to work out what i need. Let me elaborate.

I'm trying to make a program that will allow the user to create and
manage a 'visual' database of (for example) a cd collection. I want the
information inside the database to be in the form of a heirarchical list
like FXTreeList and FXDirList objects are, however i'm stumped in
relation to FXTreeList and FXDirList in the following ways:

How can i fill FXTreeList (or a more appropriate class of object) with
the relevant data? I want to be able to navigate to a directory and have
an instance of the tree list be created with only the relevant directory
structure inside. I've made DirLists which give me access to my entire
filesystem but i can't figure out where to pass the location of the
starting directory to.

I'm thinking perhaps a dirlist is simply an instance of that nature(tree
list like navigation through entire filesystem), hence my looking into
the treelist object..

How can i 'save' a TreeList? I followed a really good book "Create Lean
Mean Guis with Ruby" and the tutorial makes use of YAML to store the
state of the program (photos added to albums) for the next time the
program starts? Firstly would i be able to use yaml to store these 'tree

and secondly what about offering the user the option to 'save' to a
location on disk so that if something dictated the program had to be
reinstalled they wouldn't lose all their database data they so
painstakingly added...?

I've been trawling the internet and re-reading the FXrRuby Rdoc online
but i can't seem to get my head round this particular information..

Any help whatsoever would be greatly appreciated, even if you want to
just redirect me to somewhere i can read about this further would be

i've looked through a few posts on this forum and it seems really
friendly :)

Thanks in advance for being patient with a beginner..maybe one day i'll
be able to offer advice on this very forum myself :)

This topic is locked and can not be replied to.