I have taken over some of my colleagues applications, as he has left. Unfortunately, he and I obviously have not had the same ideas about writing code.
I have found lots of procedures in sub-units that access components, procedures and variables on/in the main form/unit directly. So far all that has been removed by moving the variables and procedures to either the unit in question or a new unit, Global.pas, used by all others. Instead of accessing components directly, I now send messages to the main form, and let that handle whatever was supposed to happen. Also in one case, where two sub-units were talking to each others form. At least compile time has now been reduced by something like a factor of 5. But is the above 'structure' the propper way of doing it ? Are there other ways, that are more efficient at run-time ? Only one thread is in use, but loads of timer events etc. _______________________________________________ Delphi mailing list -> [email protected] http://lists.elists.org/cgi-bin/mailman/listinfo/delphi

