get the last activity ID for milestone ID when selecting