Var
Script: OleVariant;
The begin
Script:=CreateOleObject (' ScriptControl);
Script. Language:=Lang;
Script. AddCode (Code);
Result:=script. Eval (Func);
end;
Procedure TForm1. Button1Click (Sender: TObject);
Var
Js: OleVariant;
STR: string;
The begin
Memo2. Lines. Text:=ExecScript (Memo1. Text, 'JavaScript' and 'signs () ");
//ShowMessage (STR);
end;
CodePudding user response:
This does not Delphi support, Delphi also just called Ole, you give the wrong should be Ole,Need to check your JS code and corresponding use of like,