AttachSecretMessage

Hello,


How could be implemented AttachSecretMessage from GoogleMaps API in VCL WebGMaps?

I had an implementation from 

Google Maps via COM (Component Object Model)

It looks like this:
 procedure AttachSecretMessage(Marker: TMarker; Num: Integer);
  var
    {$IFDEF USE_ANONYMOUS_METHODS}
    InfoWindow: TInfoWindow;
    {$ENDIF}
    InfoWindowOptions: TInfoWindowOptions;
  var
    callString : string;
  begin
   with Script do
    begin
      InfoWindowOptions := TInfoWindowOptions.Create;
      InfoWindowOptions.Content := MBParams[ActiveFilter,Num];
      {$IFDEF USE_ANONYMOUS_METHODS}
      InfoWindow:=
      {$ENDIF}
      gmAPI.New(Google.Maps.InfoWindow(InfoWindowOptions));
      {$IFDEF USE_ANONYMOUS_METHODS}
      Marker.OnClick := procedure(Sender: TObject; Event: TEvent)
      begin
        InfoWindow.Open(Marker.GetMap,Marker);
        {$ELSE}
        //Marker.OnClick := MarkerClick;
        //Compiliert nicht
        {$ENDIF}
        callString := 'GM '+MBParams[ActiveFilter,Num];
        actualSite := MBParams[ActiveFilter,Num];
        if(ClipboardCB=True) then
        begin
          Clipboard.AsText := actualSite;
        end
        else
        begin
          RunProg.RunProgramWaiting(progPath, '',callString);
        end;
      end;
    end;
    {$ENDIF}



  (* Original routine from sample EventClosure
   procedure AttachSecretMessage(Marker: TMarker; Num: Integer);
  var
    {$IFDEF USE_ANONYMOUS_METHODS}
    InfoWindow: TInfoWindow;
    {$ENDIF}
    InfoWindowOptions: TInfoWindowOptions;
  begin
    with Script do
    begin
      InfoWindowOptions:=TInfoWindowOptions.Create;
      InfoWindowOptions.Content := Message[Num];
      {$IFDEF USE_ANONYMOUS_METHODS}
      InfoWindow:=
      {$ENDIF}
      New(Google.Maps.InfoWindow(InfoWindowOptions));
      {$IFDEF USE_ANONYMOUS_METHODS}
      Marker.OnClick:=
        procedure(Sender: TObject; Event: TEvent)
        begin
          InfoWindow.Open(Marker.GetMap,Marker);
        end;
      {$ELSE}
      Marker.OnClick := MarkerClick;
      {$ENDIF}
    end;
  end;
  *)
  end;

Any help appreciated!

Peter

.
 procedure AttachSecretMessage(Marker: TMarker; Num: Integer);

is used e.g. to doubleclick on a marker and launch another program. For example the ImageBrowser of an image database is started showing all images belonging to the place name of the marker.

Peter 
See in java script api for google maps this sample!

https://developers.google.com/maps/documentation/javascript/examples/event-closure

We already support openMarkerInfoWindowHtml() with which you can do something similar. Have you checked this?

Hello


Thank you for the information. I will try.

Sincerely Peter