Name

IsLibrary Variable

Syntax

var IsLibrary: Boolean;

Description

Delphi sets IsLibrary to True in a library project (DLL) or False in a program (EXE).

Tips and Tricks

  • In most cases, you should use ModuleIsLib instead of IsLibrary to avoid complications caused by packages.

  • If a library uses the vcl50 package, and that library is loaded into an application that also uses the vcl50 package, the library and the program will share a single instance of the vcl50 package. The application sets IsLibrary to False, so the library sees the same False value for IsLibrary in the vcl50 package. Any unit you write can also be loaded simultaneously by an application and a library in the same process, so the value of IsLibrary is limited. ModuleIsLib does not have this problem.

See Also

Library Keyword, ModuleIsLib Variable, ModuleIsPackage Variable
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset