Re: A89: Re: Re: Folder List
[Prev][Next][Index][Thread]
Re: A89: Re: Re: Folder List
Thank you for the example.
----- Original Message -----
From: "Sebastian Reichelt" <SebastianR@gmx.de>
To: <assembly-89@lists.ticalc.org>
Sent: Thursday, June 22, 2000 1:00 AM
Subject: Re: A89: Re: Re: Folder List
> Hi!
>
> I finally got around to make the folder/file list header file. I included
a
> zip (sorry for posting binaries) that contains Folders.h and a small
example
> (open it in the IDE). I hope this is useful to a lot of people, because
> lists of folders and files in a folder are used very commonly. You can
> extend the entries, for example to store type information, file size, and
> extended attributes. Sorting may also be enhanced easily. By default,
all
> entries seem to be automatically sorted by name (unlike other
information).
> It might be a good idea to use sorting anyways, though, using the provided
> SortByName function. You can also specify whether to sort in ascending or
> descending order.
>
> Using the test program:
> When you run it, it asks you for a folder name, then displays a list of
> variables in that folder. If you type in an empty folder name, a list of
> non-temporary folders will be displayed. That's basically it. You can
use
> the source as an example to write your own programs.
>
> Just a tip for you programmers, so that you don't have to spend as much
time
> on it as I did: Use strncmp for strings with fixed length, such as
> SYM_ENTRY::name. Otherwise, the result will be unpredictable, even if the
> strings are different. It seems that strcmp should stop after the first
> character that is different, so the rest should be ignored, but for some
> reason that doesn't work.
>
> Bye,
> Sebastian
>
Follow-Ups:
References: