The family of a mentally ill grandfather who was shot in prison in Pakistan while facing the death penalty have hit out at David Cameron.

The Prime Minister said that contacts were being made at the highest level to try to bring Mohammad Asghar back to the UK and condemned his treatment as appalling.

But lawyers for the family of the 70-year-old from Edinburgh accused him of getting serious facts about the case wrong.

Mr Cameron yesterday suggested that Mr Asghar was still in Pakistan in part because a prison transfer agreement with the UK had been "suspended".

But solicitors for the Asghar family insisted that was wrong and they were "deeply alarmed" at the misunderstanding of the case.

"It is extremely disappointing that he is unaware of the true facts," they said.

The row centres on Scotland's separate legal system.

Last night the Scottish Government said prison transfer was a matter for the Scottish Prison Service and was "not suspended" with Pakistan.

At Prime Minister's Questions (PMQs), yesterday Mr Cameron said Mr Asghar's treatment had been "appalling".

He added: "It is particularly appalling that ... he was actually shot, while in prison, supposedly being protected by the Pakistani authorities.

"We obviously are looking at the case for a prisoner transfer, but they had to be suspended in recent years because Pakistan released prisoners that we returned to them, so there is a problem there."

He added: "But we take this case very, very seriously and are raising it at every level in Pakistan."

Aamer Anwar, solicitor for the Asghar Family, said they were "deeply alarmed" that the Prime Minister has got it so completely and utterly wrong on the question of the prisoner transfer agreement.

"It is extremely disappointing that he is unaware of the facts," he said. He also said that the Foreign Office had confirmed to Scottish Ministers that prison transfer was not suspended.

Mr Asghar, who suffers from paranoid schizophrenia, was jailed after writing letters to a number of people claiming to be the Prophet Mohammed.

He was shot last month by a police officer while on death row in a maximum-security jail.

The Foreign Office declined to comment last night.

A spokesman said: "We would not comment on conversations within government."

A Scottish Government spokesman said: "There are clear procedures for any international prisoner transfer agreement and that is a matter for the Scottish Prison Service in Scotland. The prisoner transfer agreement with Pakistan is not suspended."

The case was raised at PMQs by Mr Asghar's former MP Sheila Gilmore.

No 10 declined to comment last night.