If I put on the form (in my program) a ZQuery component and run I get a AccesViolation. The compiler stop on this line:
Code: Select all
procedure TZAbstractRODataset.Notification(AComponent: TComponent;
Operation: TOperation);
begin
inherited Notification(AComponent, Operation);
if (Operation = opRemove) and (AComponent = FConnection) then
begin
Close;
FConnection := nil;
end;
if (Operation = opRemove) and Assigned(FDataLink)// <----- Error
and (AComponent = FDataLink.Datasource) then
FDataLink.DataSource := nil;
if (Operation = opRemove) and Assigned(FMasterLink)
and (AComponent = FMasterLink.Datasource) then
begin
FMasterLink.DataSource := nil;
RereadRows;
end;
end;
Code: Select all
procedure TZAbstractRODataset.InternalPrepare;
begin
CheckSQLQuery;
CheckInactive;
CheckConnected;
Connection.ShowSQLHourGlass;
try
if (FSQL.StatementCount > 0) and((Statement = nil) or (Statement.GetConnection.IsClosed)) then// <----- Error
Statement := CreateStatement(FSQL.Statements[0].SQL, Properties)
else
if (Assigned(Statement)) then
Statement.ClearParameters;
finally
Connection.HideSQLHourGlass;
end;
end;
How to find a problem?
I don't know how to use SVN.