trigger google maps marker click
Solution 1:
i see that this question has been sitting for quite awhile, but, just in case, this answer may be helpful: trigger google maps marker click
The code would look like this:
var marker = new google.maps.Marker({});
new google.maps.event.trigger( marker, 'click' );
Good luck!
Solution 2:
I found I needed to attach a click event to the marker like so
var marker = new google.maps.Marker({});
marker.addListener('click', function() {
infowindow.open(map, marker);
});
new google.maps.event.trigger( marker, 'click' );