[Google Maps] Custom marker image not working

[Google Maps] Custom marker image not working

  
Forge Component
(14)
Published on 4 Oct by OutSystems Labs
14 votes
Published on 4 Oct by OutSystems Labs
Hi,
I'm trying to add custom image to a map marker in base64 using in Marker Options
"
{
icon: {size: new google.maps.Size(220,220),
           scaledSize: new google.maps.Size(32,32),
           origin: new google.maps.Point(0,0),
           url: ""data:image/png;base64," + BinaryToBase64(Picture)  + """,
           anchor: new google.maps.Point(16,16)}
}"
But marker in this case is not displayed at all.

I've tried to put manually JS form google maps api from this example http://jsfiddle.net/J7mf7/1/ and it worked fine. But I would like to use this component for this task as it is more reusable. Will apreciate any help.
Thank you.

Best regards,
Nick
I made it very easy by just following Google API examples.
I end up with an AddCoordinateMarkerToMap action with TriggeringEvent ="click" and Handler

"{draggable: false, title: 'Name', icon: 'img/Image.png'}"
The problem was in GenerateMarkerOptionsByPosition action that repleces } with  , and appends coordinates value. And in case of nested options the worng } was replaced. So I've made small change to this action replacing { (that always first one) - see attached image.
Hey, Mykola,

Thank you for sharing! We'll update the component to allow you to pass these parameters without having to modify it.

Best regards,

Carlos Simões