@author Xavier Martinez(cadetill) @version 1.5.4
Projekt MegaDemo
点击按钮搜索方向后,没有任何事情发生。
程序中的单位GMDirection中的程序循环执行:
ExecuteScript('GetDirections',Params); 重复 TGMGenFunc.ProcessMessages; 直到(GetIntegerField(DirectionsForm,DirectionsFormResponse)= 1); GetRetournedData;!
答案 0 :(得分:0)
我在GMMap.pas单位暂时解决了这个问题
function TGMObjects.ExecuteScript(NameFunct, Params: string): Boolean;
begin
Result := False;
Map.FDocLoaded := true; <<- new line
if (csDesigning in ComponentState) or not Assigned(FMap) or
not Map.Active or not Map.FDocLoaded then Exit;
Result := FMap.ExecuteScript(NameFunct, Params);
end;