1

When I include midaslib in my uses clause, the resource stringtable is overriden with '0: succesfull completion' and 15 empty strings.

I include a precompiled .Res file.

Original Test program :

program tesresources;

{$R BKHTEKSTEN.RES}

uses
  System.StartUpCopy,
  FMX.Forms,
  main in 'main.pas' {Form1};

  {$R *.res}

begin
  Application.Initialize;
  Application.CreateForm(TForm1, Form1);
  Application.Run;
end.
//Form1
procedure TForm1.Button1Click(Sender: TObject);
var
  i:Integer;
  astr:string;
begin
  MEMOtest.BeginUpdate;
  try
    MEMOtest.Lines.Clear;    
    MEMOTest.Lines.Add('Resourstrings : ');    
    for i := 0 to 255 do begin
      astr:=LoadStr(i);
      MEMOTest.Lines.Add(i.ToString+' : '+aStr);
    end;
  finally
    MEMOtest.EndUpdate;
  end;
end;

Result :

Resourstrings : 0 : 1 : Pingwin 5 - Fout! 2 : Ok! 3 : Pingwin 5 - Bericht ! 4 : Kan bestand niet openen ! 5 : Weet u het zeker ? 6 : Verwijderen! 7 : 8 : 9 : Opgelet : Deze informatie gaat definitief verloren !!! 10 : 11 : Opgelet : Het geselecteerde Boekjaar zal volledig verwijderd worden !!! 12 : Opgelet : De BTW Listing zal definitief verwijderd worden !!! 13 : Opgelet : Verwijderen van de Ouderdomshistorieken !!! 14 : Opgelet : Verwijderen van de Historieken klanten/Leveranciers !!! 15 : Opgelet : Deze Klant zal Definitief verwijderd worden !!! 16 : Opgelet : Deze Leverancier zal Definitief Verwijderd worden !!! 17 : Opgelet : Deze Contactinformatie zal Definitief verwijderd worden !!!

When inluding Midaslib, the resource stringtable is changed.

program tesresources;

{$R BKHTEKSTEN.RES}

uses
  System.StartUpCopy,
  FMX.Forms,
  midaslib,
  main in 'main.pas' {Form1};

  {$R *.res}

begin
  Application.Initialize;
  Application.CreateForm(TForm1, Form1);
  Application.Run;
end.

Resourstrings : 0 : Successful completion. 1 : 2 : 3 : 4 : 5 : 6 : 7 : 8 : 9 : 10 : 11 : 12 : 13 : 14 : 15 : 16 : Opgelet : Deze Leverancier zal Definitief Verwijderd worden !!! 17 : Opgelet : Deze Contactinformatie zal Definitief verwijderd worden !!!

When looking in the .exe I find two stringtables Original stringtable New stringtable

Rudy Velthuis
  • 27,475
  • 4
  • 43
  • 84
r_j
  • 1,288
  • 14
  • 33
  • If you can, use FireDAC and forget `TClientDataSet`. – Victoria Aug 01 '17 at 15:09
  • The problem arises in a big application and we cannot migrate all clientdatasets to firedac, so we need a solution in the meantime. – r_j Aug 01 '17 at 15:12
  • 1
    Move your stringtable to a different index than 1. Clearly MidasLib contains a stringtable 1 resource that is overwriting yours, and it's highly unlikely that EMBT is going to move theirs. – Ken White Aug 01 '17 at 18:13

0 Answers0