[DUG] IsClass access violation

Todd Martin todd.martin.nz at gmail.com
Thu Nov 14 16:00:06 NZDT 2013


Firstly, since TCategoryDetails is a descendant of TCustomDetails, it
should NEVER be referenced in a method of TCustomDetails.
Secondly, I would say the TCustomDetails object has already been destroyed.

Todd.

> I've got a strange error occurring for just one user where this
> procedure is failing...
>
>  
>
> procedure TCustomDetails.SetModified(Modify: Boolean);
>
> begin
>
>   FModified := Modify;
>
>   if Modify then
>
>   begin
>
>     if Self is TCategoryDetails then MainForm.CategoryChanged := True
>
>     else MainForm.SpotChanged := True;
>
>   end;
>
> end;
>
>  
>
> TCategoryDetails and another class is inherited from TCustomDetails.
>
>  
>
> Access violation at address 004047DC in module 'SPLCreator.exe'. Read
> of address FFFFFFDF.
>
> main thread ($87c):
>
> 004047dc SPLCreator.exe System                TObject.InheritsFrom
>
> 00404742 SPLCreator.exe System                @IsClass
>
> 005dc6a6 SPLCreator.exe SPMain      3831   +4 TCustomDetails.SetModified
>
>  
>
> Would this happen if Self was nil or invalid?  I don't see how that
> could happen but just wondering how this can happen.
>
>  
>
> Cheers,
>
> Ross.
>
>
> _______________________________________________
> NZ Borland Developers Group - Delphi mailing list
> Post: delphi at listserver.123.net.nz
> Admin: http://delphi.org.nz/mailman/listinfo/delphi
> Unsubscribe: send an email to delphi-request at listserver.123.net.nz with Subject: unsubscribe


-- 
/Fortune/ favours the *brave*
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://listserver.123.net.nz/pipermail/delphi/attachments/20131114/23711036/attachment.html 


More information about the Delphi mailing list