Laurence Marshall inside the London Road Church

Former city councillor Lawrence Marshall, who led the attempt to buy London Road Church at the top of Easter Road and turn it into a community hub, said the experience had been a “Kafkaesque nightmare”.

And he called for the legislation to be changed so other communities did not face the same obstacles.

Mr Marshall, former session clerk at the church, and other campaigners set up a company, In:Spire East End, to pursue the bid and secured the backing of almost 2000 residents.

Sign up to our daily newsletter The i newsletter cut through the noise Sign up Thanks for signing up! Sorry, there seem to be some issues. Please try again later. Submitting...

They wanted the church to be used as a theatre and music venue, rehearsal space and exhibitions as well as a base for scouts, guides and brownies, a club for elderly people, a community cinema, dancing and badminton. The campaigners argued the building was pivotal to a community which was the tenth most densely populated neighbourhood outside London but had few community facilities.

But the Church of Scotland had put the building up for sale after the congregation was merged with another nearby. And it refused requests to delay the sale process to allow the community bid time to put its case together.

Nevertheless the campaigners completed the documentation, the bid was accepted as valid and the Church of Scotland was stopped from selling the building while Environment Secretary Roseanna Cunningham considered whether the bid should be allowed to proceed to the next stage.

But Ms Cunningham ruled against In:Spire, saying ministers were not satisfied the group had done enough to try to acquire the church before it was put on the market.

Mr Marshall said: “It’s an outrageous decision. The legislation is flawed. According to this, we should have packed in as soon as the building was put up for sale.

“If we’d been told back then, we could have saved thousands of hours of work and not raised people’s expectations. The whole thing is like a Kafkaesque nightmare.”

And on the In:Spire Facebook page, he wrote: “The Community Right to Buy legislation is clearly failing – especially in cities. It is not fit for purpose.

“We had hoped that the Scottish Government and the Scottish Ministers would wish to support such a huge community effort as we have undertaken. We dared to believe that the Scottish Government would wish to work with us – not against us.

“Such a belief has proven to be naive. To say that we feel badly let down would be an understatement.”

The In:Spire bid came after Action Porty became the first group to use the legislation to secure a community buy-out in an urban area when they took over the former Portobello Old Parish Church and Halls in Bellfield Street for a multi-use community hub.

But London Road Church was the second attempted buy-out in Edinburgh to be rejected in just a few months. Hopes of securing the site of the Sick Kids Hospital for the community were dashed when NHS Lothian sold to developers while the buy-out bid was held up by technicalities.

The Marchmont and Sciennes Development Trust, which was behind the Sick Kids bid, added their support to the calls for the law to be changed.

A spokesman said: “Our experience of the legislation was very frustrating. It is incredibly complicated, inflexible and not written for ordinary members of communities who are doing this in their spare time and often without any experience of property laws and the like.

“The law needs to be changed to make the process simpler or the Scottish Government needs to give communities expert help to try and navigate the application process.”

Ms Cunningham said she understood the disappointment caused by the community’s failure to secure the London Road Church and the frustration felt by other groups who felt they had fallen foul of the legislation.

“The system must be as simple as possible and I’m not convinced it is working as well as it should.”

She said she had already asked the Scottish Land Commission to carry out a review into how it could be made easier for community groups to achieve a successful outcome.