Newsgroups : Borland : borland.public.delphi.nativeapi.win32 : 2005 Mar : How to know which Unit/line in source file occur exception or runtime error?

www.cryer.info
Managed Newsgroup Archive

How to know which Unit/line in source file occur exception or runtime error?

Subject:How to know which Unit/line in source file occur exception or runtime error?
Posted by:"M$" (someo..@microsoft.com)
Date:Fri, 18 Mar 2005 16:36:34

Hi all,
  i had used JCLDebug, and can get which object occur an exception, but i
can't locate the unit/line. how to do it ?
  example ,

Unit1:

procedure TForm1.Button1Click(Sender: TObject);
var
  P : PChar;
begin
  P^ := 'a';     /// Line 32
  Caption := P + 'abcd';
end;

when click Button1, it will threw a exception. i can get TFORM1, but I want
get the Unit name: UNIT1 and Line number: 32.

thanks in advance.

Replies:

www.cryer.info
Managed Newsgroup Archive