Jquery event in Google Map info window?

Jquery event in Google Map info window?

Hi,

I am new to Jquery (a bit new to javascript as well...), and i am developing a web application using Goolgle map, i found that JQuery functions inside Google Map info windows isn't firing, could anyone help? thanks in advance. Belows are some of the codes.

function addMapClickEvent() {
GEvent.addListener(map, "click", function(overlay, point) {
if (overlay) {
//map.removeOverlay(overlay);
} else {
var marker = new google.maps.Marker(point);
map.addOverlay(marker);
var html = document.getElementById('divStoreUnit').innerHTML;

$("#aCancelStoreUnit").click(function() {
alert('dsadsa');
});


marker.openInfoWindow(html);
}

});
}

aCancelStoreUnit is a <a> inside divStoreUnit which i used as the info window. I try to put the event binding in the addMapClickEvent function like above as well as in $(document).ready function, both not working...