>                     How will the code look like to save a marker

Globally define your 'last' marker variable outside of any functions.
   var myLastMarker;

Find where in your code you are making a new marker
    var marker = ... whatever it is you do to build a red marker...

Now update the last marker (if there is one ; there won't be first
time around)
    if (myLastMarker) {
       myLastMarker.setImage( url-of-something-yellow.png );
    }

And remember the new red marker in your global variable
    myLastMarker = marker ;

-- 
You received this message because you are subscribed to the Google Groups 
"Google Maps API" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-maps-api?hl=en.

Reply via email to