diff --git a/packages/fcl-db/src/sqldb/sqldblib.pp b/packages/fcl-db/src/sqldb/sqldblib.pp index 4dd0480621..cb8bec7338 100644 --- a/packages/fcl-db/src/sqldb/sqldblib.pp +++ b/packages/fcl-db/src/sqldb/sqldblib.pp @@ -38,12 +38,12 @@ implementation Resourcestring SErrConnnected = 'This operation is not allowed while the datatabase is loaded'; SErrInvalidConnectionType = 'Invalid connection type : "%s"'; + { TSQLDBLibraryLoader } procedure TSQLDBLibraryLoader.CheckDisabled; - begin - If Enabled then + If not (csLoading in ComponentState) and Enabled then DatabaseError(SErrConnnected,Self); end;