How to organize large projects in the Delphi development environment

I would like to split my large application into smaller parts in the IDE. Correctly, I have one project (MainApp.exe) with a large number of files. With so many files, I sometimes confuse where you can find the right file to modify.
It would be great if I could split my application into different parts, for example. InvoicePart, AnalysisPart, CustomerPart, ReportPart, etc. When compiling parts, one executable file must be generated. This means that I do not want to split the running * .exe application into DLLs or runtiume packages. That should just help me write the code easier.

Is there an elegant way in Delphi XE?

+7
source share
2 answers

Organize source files in folders, for example (Invoice, Analysis, etc.) . Browse the folders in the Project Manager menu.

This is a simple and uncomplicated approach.

+6
source

It is easy, but it is far from elegant.

All you have to do is split the files into different directories. Say a general analysis of bills, etc. Drive a project for each of them and put other directories in the search path in the project settings. However, this is the fastest way to get into the complete mess I have ever seen. You can easily get different results depending on the order in which you build subprojects.

First, in which project should each file be located?

How do you stop using one file in several projects.

You will have a shared folder for dcu files, several or nothing?

How do you know that the specified object file was compiled in a project that "belonged" to it? The object file is out of order with the classic head scratcher code.

If you use an integrated control source, how do you know that all relevant is relevant?

You can use a group of programs to synchronize all of them, but this does not solve many other problems.

Basically, if your only project is so big that you have this problem, you have completely lost control of it. The above will not regain control, it will just make it less obvious if you are in a hint.

Use dlls for what they are intended. I know that it will not be easy, and it will cost you, but there is the right way to do it, your current mess and your proposed mess. Bite the bullet and do it right or leave it alone, these will be the only options that I would choose.

We ended up where you offer to go, this is not a happy place.

0
source

All Articles