But he tried to stop the "nonsense stuff" the man was doing in front of his office.
He said he was "pretty sure" the police would arrive soon.
"I just made sure I knew where his arms were all the time just in case he had a change of mood on me," Mr McElrea said.
Taieri Clutha area response manager Senior Sergeant Alastair Dickie said the man became violent and resisted arrest when police arrived.
"There were a lot of people concerned and they were pointing the police in the right direction when they arrived," he said. "I'm glad we could resolve it quickly, because it could have got ugly."
A member of the construction crew yesterday said they had seen the man's knife and the foreman had called police.
Detective Constable Robin Hutton, of Balclutha, said police received "a number" of 111 calls regarding the man yesterday afternoon.
About 3pm, he had threatened a female acquaintance at a nearby residence. She had called 111.
After he left the property, the man began walking down the street "acting in a threatening and concerning manner".
When he was arrested, he had a large "kitchen-style carving knife" concealed on him.
No-one was injured as a result of the incident. The man was taken into custody and would face charges, Det Const Hutton said.
The man is scheduled to appear in Dunedin District Court today.