image thumbnail
from Handling MATLAB Events in Excel by Peter Webb
Source code for Sept. 2006 News and Notes Programming Patterns article.

DisplayLocation(city, lat, lng)
function DisplayLocation(city, lat, lng)
%#event
    disp(['Latitude = ' num2str(lat) '; Longitude = ' num2str(lng)]);
    disp(['Grid center near: ' city]);
    

Contact us at files@mathworks.com