He remained in office at Edinburgh until 2003, when he returned to the ranks of Crown Counsel as the Senior Advocate Depute. He prosecuted the significant "HM Advocate v Transco plc" case, the first ever prosecution of a public limited company for culpable homicide in Scotland, and represented the Crown in the successful 2004 appeals by Thomas Campbell and Joe Steele, convicted over the so-called Glasgow Ice Cream Wars. He was appointed Queens Counsel (QC) in 2005, in the same round of appointments as John Beckett, whom he would later succeed as Solicitor General.