OleVariant - problem with the name operator lazarus / 67-Windows ---------------------------------------------------------------------- romerws · 2019-05-13 13:27 Lazarus 1.4.2 FPC 2.6.4 A piece of code: Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i procedure ole_test;var oleObject: OleVariant; begin  ...  oleObject.Operator := 'WS';  // Fatal: Syntax error, "identifier" expected but "OPERATOR" found  ...end;   What to do? Thanks ---------------------------------------------------------------------- howardpc · 2019-05-13 18:28 You could try Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i oleObject.&Operator := 'WS';I don't have Windows, so I have not tried this myself. ---------------------------------------------------------------------- ASBzone · 2019-05-13 18:38 Quote from: howardpc on May 13, 2019, 08:28:30 pmYou could try Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i oleObject.&Operator := 'WS';I don't have Windows, so I have not tried this myself. I tried this suggestion and it compiles without issues (in both delphi and objfpc modes) The original compiles without issues if {$mode delphi} is enabled. ---------------------------------------------------------------------- romerws · 2019-05-14 06:14 It helped :-) Thank you very much.