Well, if I was to create a list of files with checks, I would do something like this:
for( %file = findFirstFile("directory/*.*"); %file !$= ""; %file = findNextFile("directory/*.*") )
{
new GuistuffThing("GUIcheck_"@%file)
{
stuff = 1;
};
new GuiTextCtrl("GUItext_"@%file)
{
text = %file;
otherstuff = 1;
};
GUIlistScroll.add("GUIcheck_"@%file);
GUIlistScroll.add("GUItext_"@%file);
}
This is un-tested and was written on the fly.