MapView.AddCircle
-----------------

Adds a circle overlay.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [MapView](component_MapView.md) | [9.4](newinversion94.md) | ✅ Yes | ❌ No | ❌ No | ❌ No | ✅ Yes |

MBS( "MapView.AddCircle"; MapView; JSON ) 

**MBS**( **"MapView.AddCircle";** /\* Adds a circle overlay. \*/  
**$MapView**; /\* The map view reference number.e.g. $$MapView \*/   
**$JSON**) /\* The JSON to describe the circle.e.g.   
{  
 "address": "Nickenich",   
 "radius": 500,   
 "title": "Monkeybread Software",   
 "subtitle": "MBS is here",   
 "color": "#FF000077"   
} \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| MapView | The map view reference number. | $$MapView |
| JSON | The JSON to describe the circle. | {    "address": "Nickenich",     "radius": 500,     "title": "Monkeybread Software",     "subtitle": "MBS is here",     "color": "#FF000077"    } |

### Result

Returns identifier or error.

### Description

Adds a circle overlay.  
The JSON may contain the following entries:  
| latitude | The latitude of the coordinate. |
|---|---|
| longitude | The longitude of the coordinate. |
| address | The address to lookup to find latitude or longitude. |
| radius | The radius in meter. |
| title | The title for the circle. |
| subtitle | The subtitle for the item. |
| strokeColor | The stroke color as name or hex notation. |
| fillColor | The fill color as name or hex notation. |
| identifier | The identifier to use. Can be empty to get new identifier auto assigned. |

  
You can either pass latitude and longitude together or pass the address and we lookup it to find coordinates.  
### Examples

Add circle for MBS with address string:

 Set Variable \[ $r ; Value: MBS ( "MapView.AddCircle"; $$MapView ; "{ \\"address\\": \\"Nickenich\\", \\"radius\\": 500, \\"title\\": \\"Monkeybread Software\\", \\"subtitle\\": \\"MBS is here\\", \\"color\\": \\"#FF000077\\" }") \]  
Add circle for MBS with coordinates:

 Set Variable \[ $r ; Value: MBS ( "MapView.AddCircle"; $$MapView ; "{ \\"longitude\\": 7.329722 , \\"latitude\\": 50.413333 , \\"radius\\": 500, \\"title\\": \\"Monkeybread Software\\", \\"subtitle\\": \\"MBS is here\\", \\"color\\": \\"#FF000077\\" }") \]  
### Release notes

- **Version 9.5**
    - Fixed [MapView.AddCircle](http://www.mbsplugins.eu/MapViewAddCircle.shtml) function, so [MapView.Overlays](http://www.mbsplugins.eu/MapViewOverlays.shtml) reports the circles.
- **Version 9.4**
    - Added [MapView.AddCircle](http://www.mbsplugins.eu/MapViewAddCircle.shtml) function.

### Example Databases

- [Mac and iOS/MapKit/MapView BeeExample](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/Mac%20and%20iOS/MapKit/MapView%20BeeExample.shtml#18ScriptAnchor_)

### Blog Entries

- [New functions of the MBS Plugin Version 9.5](https://www.mbsplugins.de/archive/2019-11-21/New_functions_of_the_MBS_Plugi/monkeybreadsoftware_blog_filemaker)
- [Neue Funktionen des MBS FileMaker Plugin 9.4](https://www.mbsplugins.de/archive/2019-10-05/Neue_Funktionen_des_MBS_FileMa/monkeybreadsoftware_blog_filemaker)
- [MBS FileMaker Plugin, version 9.5pr1](https://www.mbsplugins.de/archive/2019-10-02/MBS_FileMaker_Plugin_version_9/monkeybreadsoftware_blog_filemaker)
- [MBS FileMaker Plugin, version 9.4pr6](https://www.mbsplugins.de/archive/2019-09-09/MBS_FileMaker_Plugin_version_9/monkeybreadsoftware_blog_filemaker)

This function is free to use.

Created 7th September 2019 , last changed 11st September 2019

  
[MailComposer.SetTORecipients](MailComposerSetTORecipients.md) - [MapView.AddPin](MapViewAddPin.md)

[HTML Version](MapViewAddCircle.shtml)