Former News of the World editor Andy Coulson has been cleared of perjury at the trial of former socialist MSP Tommy Sheridan after the case against him collapsed.
Coulson, 47, had been on trial for around two weeks at the High Court in Edinburgh, where he denied committing perjury during the 2010 case in Glasgow.
Trial judge Lord Burns upheld a defence motion that Coulson, from Kent, a former director of communications for the Prime Minister, had no case to answer.
Delivering his ruling, Lord Burns said he had "sustained the arguments in favour of the accused" and told Coulson: "I acquit you of the charge."
The acquittal centred on the argument that Coulson's allegedly false testimony in 2010 was no relevant to the outcome of that case.
The judge gave his decision on Monday following two days of legal submissions from Coulson's defence QC but it could not be reported until today as the Crown was given time to decide whether to appeal against the ruling.
The development means Coulson now has no more criminal cases to answer.
He had been facing a further trial for conspiracy to commit misconduct in public office over the purchase of royal telephone directories from a police officer by the News of the World.
But he was one of nine journalists to have charges against them dropped in April following a review of all Operation Elveden cases by the Crown Prosecution Service.
Coulson was sentenced to 18 months jail in July 2014 after being found guilty of conspiracy to intercept mobile phone messages.
He served just under five months, most of which in Belmarsh high security prison.
During the latest Coulson trial, the Crown led evidence from several former journalists at the paper as they tried to build a picture of practices there while Coulson was editor – a position he held from January 2003
until he resigned in January 2007.
But when the prosecution closed its case on Tuesday last week after seven days of evidence, Coulson's legal team lodged a submission that there was no case to answer and among the arguments said the evidence
alleged to be false in this case was not relevant to the then live issues – the charge of perjury in Sheridan's trial.
The prosecution case centred around what it alleged to be lies told by Coulson under oath at Sheridan's trial more than four years ago.
Sheridan was on trial for perjury at that stage and, while conducting his own defence, called Coulson as a witness over two days at the High Court in Glasgow in December 2010.
Sheridan's trial was in respect of evidence he gave in an earlier 2006 civil action.
Coulson's trial heard that, following publication of a series of articles in the News of the World, Sheridan raised a defamation action in Scotland's Court of Session against the newspaper's
publishers, News Group International.
The jury in the subsequent 2006 action decided that the politician had been defamed by the newspaper and it was ordered to pay him £200,000 in damages.
But in January 2011, Sheridan was jailed for three years after being found guilty of lying about the now-defunct tabloid's claims that he was an adulterer who visited a swingers club.
Prosecutors in the latest trial alleged that Coulson made false claims on December 9 and 10, 2010, after being sworn in as a witness in Glasgow.
The charge against Coulson alleged he had falsely stated that before the arrest of private investigator Glenn Mulcaire and News of the World journalist Clive Goodman on August 8 2006, he did not know that Goodman
was involved in phone-hacking with Mulcaire.
It was alleged that Coulson had falsely said that he did not know that payments were made to Mulcaire by Goodman and he did not know of Mulcaire's "illegal activities".
The Crown also alleged that Coulson was wrong when he said he did not have any email exchanges with Goodman in relation to Mulcaire and falsely stated that he did not know of Mulcaire, had not heard his
name and did not know that he was employed by the tabloid.
Coulson had pleaded not guilty to the allegations against him.
The jury of nine men and six women had heard a recording of the evidence Coulson gave in Sheridan's court case.
The jurors heard him tell Sheridan that he had stepped down from the role of editor after Goodman was convicted of phone-hacking.
On the 2010 tape he was heard saying he "had no knowledge" of phone-hacking but chose to resign as he felt he "had to take responsibility for it".
"Things went badly wrong at the News of the World under my editorship and that's why I quit," Coulson said on the tape.
The court also heard from senior journalists at the paper at the time Coulson was in charge.
They included Goodman, a one-time royal editor at the tabloid, who pleaded guilty to phone-hacking offences in 2006.
Next up was Neville Thurlbeck, the paper's one-time chief reporter, followed by James Weatherup, a former news editor at the tabloid.
In subsequent legal argument which could not be reported until now, defence counsel Murdo Macleod QC told the judge: "It's not a hacking trial, it's a trial about perjury."
Macleod told the judge, in the jury's absence, that in order to constitute perjury, the evidence alleged to be false must have been relevant to the original trial.
He pointed to the defence's closing speech in 2010, in which Sheridan said: "The reason I risked my defence to cite the likes of … Andy Coulson to give evidence wasn't because I thought they were going to
help my defence, it was because I think I have a public service and a public duty to try and expose wrongdoing…"
Macleod called this section of his speech a "clear demonstration of irrelevance".
"It's as plain as a pikestaff," he said.
Macleod said what the Crown "could not get away from" was that Sheridan and the advocate depute in the original trial "had deemed Mr Coulson's evidence as irrelevant".
But prosecutors argued that the evidence was relevant because the defence in the original proceedings had taken a position that practices at the News of the World, including hacking, could have allegedly facilitated the manufacture of a disputed video tape which was entered as evidence in Sheridan's trial.
The Crown argued that the questioning of Coulson on whether he knew about hacking was in order for the defence to support that position and therefore relevant to its case.
But the defence pointed to the agreed facts in this trial that there was no evidence of any unlawful interception of messages left on Sheridan's phone during the original trial.
Macleod said the Crown could not "ride two horses" and say evidence was irrelevant in the original trial, and then later rely on it as relevant in this trial.
"Not only is he (the Lord Advocate) seeking to ride two horses, the two horses are galloping in opposite directions," Macleod said.
Lord Burns told Coulson today: "You may leave the dock."
Coulson walked to the back of the courtroom and sat down to listen to the judge discharge the jury.
Lord Burns told jurors he would explain what had happened on the days they were not in court.
He said: "To prove the charge against Mr Coulson, the Crown needed to prove that the allegedly false evidence given by Mr Coulson was relevant to the issues which arose in Mr Sheridan's trial for perjury or Mr
Coulson's credibility in the important evidence he gave at that trial.
"That was the matter of law for me. A judge's question. Relevancy is always a judge's question."
He told them: "After two days of legal submissions last week and having considered the matter, I decided that the Crown had not led sufficient evidence to satisfy me that the allegedly false evidence was relevant to
proof of the charge in Mr Sheridan's trial or Mr Coulson's credibility at that trial."
Following today's hearing, a Crown Office spokesman said: "Andrew Coulson was a defence witness at the trial of Tommy Sheridan. He gave his evidence without objection as to relevancy.
"The Crown indicted Coulson on the basis that he lied during parts of his evidence, in particular that he had no knowledge of phone-hacking.
"The trial judge in the Coulson trial, at the conclusion of the prosecution evidence, ruled that this evidence was irrelevant and therefore could not found the basis for a prosecution for perjury.
"This brings proceedings to an end."
In his written decision, Lord Burns said: "I consider that the false evidence alleged in this indictment was not relevant evidence at the original trial and the charge of perjury in the indictment is
Coulson said outside court: "I am obviously delighted by the judge's decision today. It was the right decision. I would like to thank him, I would like to thank the jury for their patience and I would like to
thank my brilliant legal team.
"This prosecution was always wrong. I didn't lie and the prosecution, in my view, was a gross waste of public money.
"I am just delighted that after four pretty testing years that my family and myself have finally had a good day."