Create a callback function:
function cell_select_callback(h, ind)
dates = get(h, 'data');
d = dates(ind.Indices(1), ind.Indices(2));
if d == 0
return
end
dn = datenum(2012, 12, d); % you have to have year & month here
fprintf('cell_select_callback(): click at [%d %d] on %s\n', ind.Indices(1), ind.Indices(2), datestr(dn));
return
and add into uitable() arguments: uitable(..., 'CellSelectionCallback', @cell_select_callback)
.
When pressed, cell_select_callback will print the coordinates of the click and the date, for example:
cell_select_callback(): click at [2 3] on 04-Dec-2012