The 27-year-old was rescued by passers-by following the incident in Dalbeattie, Dumfries and Galloway, on Saturday.