Officers were called to Stewart Place in the village of Wanlockhead in Dumfries and Galloway at around 8.20pm yesterday.
A 17-year-old man had allegedly threatened another man with a knife and police set up a cordon around a property and called in an armed response unit.
The teenager gave himself up after around an hour and was taken into police custody.
A force spokesman said: “Police attended and the area surrounding the incident was cordoned off to ensure public safety. Armed police officers traced the male a short time later and the incident was brought to a safe conclusion after about an hour when he surrendered to police.”