He was standing near the crane guiding it when it touched the power line.
He was taken by air ambulance to the Royal United Hospital in Bath.
A Wiltshire Air Ambulance spokesman said: “A male sustained an electric shock whilst working on a building site. On arrival he was in cardiac arrest.
“The patient was defibrilated and a heart rate restored. The patient was stabilised and flown to Royal United Hospital.”
The Wiltshire Times said the crane was moving steel beams into place as part of work to build the new clubhouse.
The paper said the site is being run by Ashford Homes.