DeepL4Delphi icon indicating copy to clipboard operation
DeepL4Delphi copied to clipboard

Compiling with Delphi 10.0 Seattle

Open jrathlev opened this issue 2 years ago • 1 comments

  1. TStringList.AddPair is not available in Delphi 10.0 Seattle.

Proposed workaround:

{$IF CompilerVersion <31.0}  // 10.1 Berlin
type
  TStringListHelper = class helper for TStringList
    function AddPair (const AName,AValue : string) : integer;
    end;

{ ------------------------------------------------------------------- }
function TStringListHelper.AddPair (const AName,AValue : string) : integer;
begin
  Result:=Add(AName+NameValueSeparator+AValue);
  end;
{$ENDIF}
  1. TJsonArray has no default property

Propsed change:

JSO2 := JSA.Items[0] as tjsonobject;

jrathlev avatar Aug 14 '23 11:08 jrathlev

Thanks, I'll install a Seattle on a VM and will update the library soon.

DeveloppeurPascal avatar Aug 14 '23 12:08 DeveloppeurPascal