It must further the charity's aims to sell and reapply the money (or pay off debt), so selling the only asset when the charity was set up to own it wouldn't usually meet that criterion. For example, it is very difficult to sell an alms house.
This case may be different, as I said, if the purposes were defined so as to include the possibility of the viaduct being used for a reopened railway. It depends on the words.
The viaduct is not the sole purpose of the charity, and it will still have plenty to spend money on.
As it is arguing about the price it is being offered by a public body for a structure it owns to be used as arguably a public asset, it may be worth pondering the ^300,000 it says it spent on maintenance. Edinburgh and Lothians Greenspace Trust (ELGT) spent ^3.9 million in the 7 years to 2013 on improvement works to the area's parks and open spaces, including, I assume, the viaduct. It is a charity and a company limited by guarantee, and its board of directors includes councillors from each of the local authorities whose surroundings it strives to improve.
It did not get that ^3.9 million entirely by shaking tins under the noses of pensioners in the foyer of the local Sainsbury. My research revealed a report to the Finance and Resources Committee of Edinburgh City Council(ECC) available
here - see item 7.11. That shows that ^1.7m of that cash came from the City Council itself, on the basis that ELGT had access to funding of the further ^2.2m. A look at
ELGT's website shows that Scottish Natural Heritage and ECC provide the core funding, presumably with the biggest donor named first. There is then a list of other funders, which includes Forestry Commission Scotland, Edinburgh Airport, the Postcode lottery, and various other trusts and businesses. The greater part of their finances are obtained directly or indirectly from the public purse.
In that context, it seems to me a little churlish for a body funded by public funds to ask an elected body to replace those public funds it expended on maintaining the bridge from public funds. The principle of compensation is to restore the person being compensated as closely as possible to the position they were in before the loss. Here, it can be argued that the actual loss to the trust was minimal. In that case, the payment could be justified at a level which reflects the proportion of the ^300,000 spent that was actually raised from private individuals. Not what it would cost to build or buy a new viaduct.