# Marker-Related Methods

> Source: https://manual.pvxplus.com/extended-nomads-objects/google-maps-interface/marker-related-methods

Below is a list of the marker-related methods supported by the PxPlus Google Maps Extended Control.

| **Method** | **Description** |
| --- | --- |
| **addMarker(latitude,longitude \[***,title$, icon$, zIndex*\]) | Adds a marker at the specified latitude and longitude. Returns a numeric identifier to be used when referencing the marker in marker-related methods.<br>The following arguments are optional:<br>\|  \|  \|<br>\| --- \| --- \|<br>\| *title$* \| Title is displayed in the marker tip. \|<br>\| *icon$* \| URL to image to be used for the marker. \|<br>\| *zIndex* \| Markers are displayed in order of their zIndex; those with higher values are displayed in front of those with lower values. By default, markers with lower latitudes take precedence. \| |
| **clearMarkers( )** | Removes all markers from the map. |
| getMarkerClickable(*markerid*) | Returns a Boolean value indicating whether the specified marker is clickable. |
| getMarkerDraggable(*markerid*) | Returns a Boolean value indicating whether the specified marker is draggable. |
| getMarkerFlat(*markerid*) | Returns a Boolean value indicating whether the specified marker is flat (i.e. has no shadow). |
| getMarkerIcon$(*markerid*) | Returns the URL of the image for the specified marker. |
| getMarkerLatitude(*markerid*) | Returns the latitude in degrees of the specified marker. |
| getMarkerLongitude(*markerid*) | Returns the longitude in degrees of the specified marker. |
| getMarkerPosition$(*markerid*) | Returns a comma-separated string containing the latitude and longitude in degrees of the specified marker. |
| getMarkerTitle$(*markerid*) | Returns a string containing the title of the specified marker. |
| getMarkerVisible(*markerid*) | Returns a Boolean value indicating whether the specified marker is visible. |
| getMarkerzIndex(*markerid*) | Returns the zIndex of the specified marker. |
| removeMarker(*markerid*) | Remove the specified marker. |
| setMarkerClickable(*markerid, flag*) | Sets whether or not the specified marker is clickable. Flag is Boolean. |
| setMarkerDraggable(*markerid, flag*) | Sets whether or not the specified marker is draggable. Flag is Boolean. |
| setMarkerFlat(*markerid, flag*) | Sets whether or not the specified marker is flat. Flag is Boolean.<br>Note:  <br>If an icon is specified, the marker will be flat. |
| setMarkerOptions(*markerid, options$***)** | Sets marker attributes specified in *options$* for the given marker.<br>*options$* contains a list of SEP-separated values pairs, consisting of attribute names and values in the format *attribute=value*.<br>Boolean values can be specified using **0** and **-1**, or **true** and **false**. Null string values can be specified by leaving the value blank.<br>***Example:***<br>"draggable=true"+SEP+"title="+SEP+"+"icon=file:///work/images/star.bmp"+SEP |
| setMarkerPosition(*markerid, latitude, longitude*) | Move the specified marker to the given latitude and longitude. |
| setMarkerTitle(*markerid, title$***)** | Sets the title of the specified marker. The title is displayed as the marker tip. |
| setMarkerVisible(*markerid, flag*) | Sets whether or not the specified marker is visible. Flag is Boolean. |
| setMarkerzIndex(*markerid, n*) | Sets the zIndex of the specified marker. |
