The last few weeks have been very difficult. The implementation of the Numbering by Surname (See July 2, 2002) had several false starts. The idea to use the Name index didn’t pan out, since the name index is not created until the report sections are generated.
Then I thought I might modify my Ancestor and Descendant code to not create the report sections or mark the people when Surname numbering is done. This also ended up being no good because the “Related Through Marriage” people could not be determined unless the people are marked. Also, the Ancestor and Descendant routines were already very complicated and any changes to them now would not be wise.
Finally, I figured out what might work. Create the Report Sections by family first. Then make an alphabetical surname list of all the Ancestors. Finally, clear the report sections, and recreate them from the alphabetical surname list.
After finally figuring out how to do Numbering by Surname, it is time to implement it.