Jump to content

Jacek Laskowski

Members
  • Content Count

    267
  • Joined

  • Last visited

  • Days Won

    2

Everything posted by Jacek Laskowski

  1. Jacek Laskowski

    MMX for Delphi 10.3 Rio

    I noticed one regression in the last beta version of MMX. When I add a local variable via ctrl+L the default text is not selected in the "Type name" field. So when I start typed the new text, the new one sticks to the old one and the stupidity comes out πŸ™‚
  2. Jacek Laskowski

    MMX for Delphi 10.3 Rio

    @Uwe Raabe I sent the log file via private message
  3. Jacek Laskowski

    MMX for Delphi 10.3 Rio

    Yes, now logs working! I wait for freeze πŸ˜‰
  4. Jacek Laskowski

    MMX for Delphi 10.3 Rio

    I don't make any logs either. I don't have a CodeSite installed, is it necessary?
  5. Jacek Laskowski

    FireDAC and read table metadata

    I use Firebird and I use domains in databases. CREATE TABLE RESOURCE ( IDRESOURCE D_PRIMARY_KEY, IDCUSTOMER D_FOREIGN_KEY NOT NULL, LASTUSED D_DATETIME, RESOURCEIDENTIFIER D_VARCHAR120, FRIENDLYRESOURCENAME D_VARCHAR250); How to use Firedac to read the domain names used for the columns in the table? I try use TFDMetaInfoQuery but without success (ExtendedMetadata enabled). ps. How to use TFDMetaInfoQuery.MetaInfoKind with value set to mkTableTypeFields? There is no description in the documentation and TFDMetaInfoQuery does not return anything.
  6. Jacek Laskowski

    FireDAC and read table metadata

    Thanks @Dmitry Arefiev !
  7. Jacek Laskowski

    MMX for Delphi 10.3 Rio

    Yes, despite the exclusion of the pointed modules, I have the IDE suspension But it is worth adding that I have a suspension after I modify the interface method and then I try to edit (ctrl+E) the method in the class that corresponds to the modified interface method. This is probably the only (certainly the main >90%) case of suspension.
  8. Jacek Laskowski

    MMX for Delphi 10.3 Rio

    Yuuppii! πŸ™‚ I will try this workaround and test behaviour, thanks for effort and for support MMX! From the more complicated code I use Spring4D, FireDAC and mORMot, did you check them?
  9. Jacek Laskowski

    MMX for Delphi 10.3 Rio

    @Uwe Raabe Some time ago I discovered that GExperts in "Uses Clause Manager" module has a parser that works in the background and creates files from the cache on the disk. Previously I suspected that MMX suspensions occur when accessing source files, so I thought GExperts might interfere with MMX somehow. I completely disabled "Uses Clause Manager" and since then the number of IDE suspensions when using MMX has dropped dramatically. It still happens, but this is maybe 10% of the previous state. I hope this helps a little bit.
  10. I have problem with one factory. definition TSQLDataSuiteWorkerMethod = procedure(const aDataSuite : ISQLDataSuite) of object; TSQLDataSuite = class(TInterfacedObject, ISQLDataSuite) [...] public constructor Create(const aTableName: RawByteString; const aSQLKind: TModifyingSQLKind; const aProcessSQL : Boolean = True; const aBeforeWorkerMethod: TSQLDataSuiteWorkerMethod = nil; const aAfterWorkerMethod: TSQLDataSuiteWorkerMethod = nil); reintroduce; end; {$M+} TSQLDataSuiteFactory = reference to function(const aTableName: RawByteString; const aSQLKind: TModifyingSQLKind; const aProcessSQL : Boolean = True; const aBeforeWorkerMethod: TSQLDataSuiteWorkerMethod = nil; const aAfterWorkerMethod: TSQLDataSuiteWorkerMethod = nil): ISQLDataSuite; {$M-} container registration aContainer.RegisterType<TSQLDataSuite>.Implements<ISQLDataSuite>; aContainer.RegisterFactory<TSQLDataSuiteFactory>; resolve in code: fSQLDataSuiteFactory : TSQLDataSuiteFactory; var Data: ISQLDataSuite; begin Data := fSQLDataSuiteFactory('TableName', TModifyingSQLKind.SQLInsert, True, nil, nil); And after last l get exception from Spring4D: Unsatisfied constructor on TSQLDataSuite What have I forgotten? I use in the program dozens of factories, classes and interfaces, all based on the spring container, everything works correctly, only this case I cannot understand. ps. maybe it's worth opening a subforum for Spring4D?
  11. Jacek Laskowski

    [Spring4D] Factory and "Unsatisfied constructor"

    I think you mean this piece of code (from the SelectEligibleConstructor method): end).TakeWhile( function(const injection: IInjection): Boolean begin if maxCount = -1 then maxCount := injection.DependencyCount; if targetType = nil then targetType := injection.Target.Parent; Result := (injection.DependencyCount = maxCount) and (targetType = injection.Target.Parent); end).Where(... But how (at this point) to get to the list of arguments and their types to choose the right constructor?
  12. Jacek Laskowski

    [Spring4D] Factory and "Unsatisfied constructor"

    What is ConstructorSelector? I didn't find anything in Spring4D sources or google. Give me a simple example, please.
  13. Jacek Laskowski

    [Spring4D] Factory and "Unsatisfied constructor"

    @Stefan Glienke Your example works, my code doesn't. It's identical*. I spent a lot of hours and energy modifying the code from left to right... I finally found it! Please add a line in your example before registering classes in the container: globalContainer.AddExtension<TActivatorContainerExtension>; and then check it out... πŸ™‚ I'm very tired of it... give me a tip how to fix it, please. * - almost
  14. Jacek Laskowski

    [Spring4D] Factory and "Unsatisfied constructor"

    When I comment on one of the constructors, then the factory was working properly. TSQLDataSuite = class(TInterfacedObject, ISQLDataSuite) [...] public // constructor Create(const aTableName: RawByteString; // const aSQLKind: TModifyingSQLKind; // const aProcessSQL : Boolean = True; // const aBeforeWorkerMethod: TSQLDataSuiteWorkerMethod = nil; // const aAfterWorkerMethod: TSQLDataSuiteWorkerMethod = nil); overload; constructor Create(const aTableName: RawByteString; const aSQLKind: TModifyingSQLKind; const aProcessSQL : Boolean); overload; end; There is a problem with factory when a class has two active constructors. But I can't understand it.
  15. Jacek Laskowski

    [Spring4D] Factory and "Unsatisfied constructor"

    I add new constructor to TSQLDataSuite: constructor Create(const aTableName: RawByteString; const aSQLKind: TModifyingSQLKind; const aProcessSQL : Boolean); overload; And new factory: ISQLDataSuiteFactory = interface(IInvokable) ['{A101FA06-ED33-478A-9066-821BC8C5E2AE}'] function Create(const aTableName: RawByteString; const aSQLKind: TModifyingSQLKind; const aProcessSQL : Boolean ): ISQLDataSuite; overload; function Create(const aTableName: RawByteString; const aSQLKind: TModifyingSQLKind; const aProcessSQL : Boolean; const aBeforeWorkerMethod: TSQLDataSuiteWorkerMethod; const aAfterWorkerMethod: TSQLDataSuiteWorkerMethod): ISQLDataSuite; overload; end; but after call: var fSQLDataSuiteFactory : ISQLDataSuiteFactory; [...] lData := fSQLDataSuiteFactory.Create('TableName', TModifyingSQLKind.SQLInsert, True); I stiil get exception: Unsatisfied constructor on type: TSQLDataSuite How to do it right?
  16. I have a spring collection, like a IList<T>. I need to remove all items from it that meet the condition: type TFoo = interface function Value : Integer; end; var List : IList<TFoo>; begin i := 0; while i < List.Count do begin if List[i].Value < 100 then List.Delete(i) else Inc(i); end; end; Can it be done faster, better? And how can I do that for IDictionary<K, V>?
  17. Jacek Laskowski

    Removal of startup Plug-In in Delphi Rio

    I use this option for years, without problems.
  18. Jacek Laskowski

    Removal of startup Plug-In in Delphi Rio

    @Vandrovnik Please add: " Windows Registry Editor Version 5.00 [HKEY_CURRENT_USER\Software\Embarcadero\BDS\19.0\Editor] "DefaultFileFilter"="Borland.FileFilter.UTF8ToUTF8" After setting this value Delphi will encode new units in UTF-8 with BOM."
  19. Jacek Laskowski

    Debugger in 10.3.3 is useless :'(

    Maybe you're using automatic inline? {$INLINE AUTO} from docs: "Behaves like {$INLINE ON}, with the addition that routines not marked with inline will be inlined if their code size is less than or equal to 32 bytes."
  20. Jacek Laskowski

    Sourcetrail support for Delphi

    Very interesting tool! Maybe Emba should consider writing a plugin to support Delphi?
  21. Jacek Laskowski

    RAD Studio 10.3.3 now available

    This is Spar.... Embarcadero! πŸ˜‰
  22. Jacek Laskowski

    HTML Library limited offer

    I downloaded hcldemo.zip again, but db still not found. --- after some time --- Now is ok, thanks.
  23. Jacek Laskowski

    HTML Library limited offer

    Happy birthday. but when I download and run demo I get exception on db connection (bad path):
  24. Jacek Laskowski

    D10.2 Ideas/Thoughts on a project...

    Then you may want to consider creating a mailing queue based on e.g. pipes (or tcp/ip). So the DLL would be a server reading the queue/pipe, and the application in the Cobol would work as a client? I don't know what possibilities Cobol has and if it supports pipes api. https://docs.microsoft.com/en-us/windows/win32/ipc/pipes
  25. Jacek Laskowski

    D10.2 Ideas/Thoughts on a project...

    I don't think there is a specification of this format anywhere described (I haven't met it). But from what I understood you want to write data to XML in order to read them in the DLL, so why do you need to know the format? If you want to have XML for another purpose then you can create it yourself using any XML library.
Γ—