ShowInfoWindowTabs

(TMarker.ShowInfoWindowTabs Method)

Displays an info window with tabs which can be set in a marker’s click event. As this is assigned to the marker’s click event, there is no need for providing the location (latitude and longitude). The width, height and border of the info window can be specified using the string styleStr. The window label text is given by string myLabel and the window content text to be displayed in the tabs is given by the array myContent . The tab array objects are created using the TtabObject(tab_label,tab_content) function which takes the label and content of the tab as the input.
public ShowInfoWindowTabs(styleStr, myLabel, myContent):Void

Parameters

  • styleStr : String - Set the width,height and border of the info window.
  • myLabel : String - Set the label text.
  • myContent : Array - Set the window content text to be displayed in the tabs.
  • Returns

  • Void
  • Example

    The following example creates a map, adds a layer , and a marker with the text "Text Marker0". It then opens an info window with tabs at said marker.
    <div id="mapContainer"  style="width: 640px; height: 400px;"></div>
    <script type="text/javascript">
        var map0 = new TMap(mapContainer, 25.7590256665386, -80.3738769902151, 15, mapLoaded, 1, true, "", "hybrid");
    
       
        function mapLoaded() {
            var layer0=map0.AddLayer();
            var marker0=layer0.AddMarker(25.759025666538, -80.3708769902151, "Show tabs");
            var tab0 = new TTabObject("Hello", "This is tab0");
            var tab1 = new TTabObject("Hello, again", "This is tab1");
            var tabArray = new Array();
            tabArray[0] = tab0;
            tabArray[1] = tab1;
            marker0.ShowInfoWindowTabs("width=240;height=100", "Simple info window", tabArray);
           
    </script>
        

    See also

  • ShowInfoWindow()
  • TtabObject