Posted on 2001-08-13
When referring to another unit in a Delphi 4 app I get the following error...
Project SysAdmin.exe raised exception class EAccessViolation with message 'Access violation at address 0046C332 in module 'SysAdmin.exe'. Read of address 000002F0...'
This happens when a unit called 'frmBoxName' refers to a unit called 'frmDeleter' like this...
with frmDeleter do
if gridDeleter.RowCount > 0 then
btnOK.Enabled := True
btnOK.Enabled := False;
The error occurs on the first 'if' statement. If I comment out this entire procedure the same error occurs next time I refer to frmDeleter.
In fact, I get the error whenever any of my forms refer to any of the others...
Both frmDeleter and frmBoxName are included in each other's relevant uses clause.
I'm sure this is really easy, because I'm sure I've done it before successfully and I've done something really daft this time...