Knowledgebase: EurekaLog V7
7.x: I get error about ExceptionLog unit being deprecated
Posted by Aleksandr Alekseev on 23 July 2012 08:48

Problem:

I get "Unit 'ExceptionLog' is deprecated" error when compiling my application. However, when I try to remove this unit - I get many "undeclared identificator" errors.

Reason:

ExceptionLog unit is unit from EurekaLog 6. It's included in EurekaLog 7 to import old EurekaLog 6 applications. However, it was marked as "deprecated" to indicate that your application uses old code (i.e. code from EurekaLog 6). 

EurekaLog 7 uses ExceptionLog7 unit instead (and additional units - see below).

Solution:

Please note that this message is not error. Your application will be compiled and run. It will function properly. This message is a warning. A warning that notify you that your project uses old code.

It's perfectly fine to use ExceptionLog unit in your application. If you have old EurekaLog project and then you upgrade EurekaLog to version 7 and import your project - it will be imported in compatibility mode and ExceptionLog unit will be used. Now you can recompile your application and it should work as before. Almost no code change is required.

If you don't want to see warnings about unit being deprecated - you can either turn off these notification in project options or use $WARN UNIT_DEPRECATED ON/OFF directives to selectably turn these warnings messages on/off for parts of your code.

However, if you want to upgrade your code, then you must disable compatiblity mode and replace ExceptionLog references with references to ExceptionLog7 unit. Also, when you start a new project - then you will use new units by default (since there is no already written code).

Note that EurekaLog 7 is a major re-design of EurekaLog 6. EurekaLog 6 contains almost everything in one single unit (ExceptionLog), while EurekaLog 7 split code into several units (such as ECallStack, EModules, ESysInfo, EExceptionManager, EDebugInfo, ESend, EDialog, etc.). That's why you may need to additionally include other units to your uses clause. If you get "undeclared identificator" error - then some unit is missing from uses. You can run a file search in \Source folder of EurekaLog installation for *.pas files containing your missed identificator (this will work also for editions without full source code, as they contain headers). Alternatively, you may study changes in EurekaLog 7.

See also:


Help Desk Software by Kayako Resolve