>I cannot use the number of levels deep, because the display often starts in the middel of a thread (like for messages after a certain date). I also have problems figuring out how to sort in a way that accommodates threads that split into several sub-threads - so sorting by date/time is not an option.
So, just like the UT.
Perhaps the function I mentioned previously can search back (from each message to its "parent"), but limit the search to messages after a certain datetime.
As to sorting, this can indeed be quite problematic. The idea is to sort messages so that a message and its reply appear together.
Is the discussion over the web, or over an office network?
For the office network, a treeview would help keep the messages together (see the sample that comes with VFP, to take a look at the treeview).
For the Web - well, don't ask me.
HTH, Hilmar.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)