GetCurrentCallStack function

Top  Previous  Next

EurekaLog includes a function named GetCurrentCallStack, that enables you to obtain the current call-stack.

 

Syntax of this function is as follows:

 

function GetCurrentCallStack: TEurekaStackList;

 

 

Example:

 

 

uses ExceptionLog; // The required unit...

 

var

   CallStackList: TStringList;

   CallStack: TEurekaStackList;

begin

   CallStackList := TStringList.Create;

   try

     CallStack := GetCurrentCallStack;

     try

       CallStackToStrings(CallStack, CallStackList);

       // ...

       // Use the CallStackList here...

       // ...

     finally

       CallStack.Free;

     end;

   finally

     CallStackList.Free;

   end;

end;