delphi 7. How to check whether the unit file exists and add it with (directives?) to compile with the project -


i have unit part of several modules(dll, applications).

in of them need use in module classes.

is possible use compiler directives (or other methods) include unit file in case included in project?

thanks!

if understood correctly, answer yes. can use conditional define in uses clause:

uses {$ifdef use_mystuff}   myunit, {$endif}   classes, windows; 

and define (or not) conditional define use_mystuff in project options.

see $ifdef, $define , $include directives , conditional compilation.


Comments

Popular posts from this blog

javascript - Iterate over array and calculate average values of array-parts -

iphone - Using nested NSDictionary with Picker -

objective c - Newbie question -multiple parameters -