for television. He subsequently wrote a number of plays for, amongst others, The Wednesday Play and Play for Today BBC anthology series, frequently in collaboration with the producer Kenith Trodd. Gray wrote 40 plays and screenplays for the stage, television, and film and eight volumes of memoirs based on his diaries. Wise Child, an adaptation of a TV play deemed too shocking for the small screen, was his first stage play. It starred Simon Ward and Alec Guinness and was produced by Michael Codron at Wyndham's Theatre in 1967. Subsequently, he wrote original plays for both radio and television and adaptations, including a TV adaptation of The Rector’s Daughter, by F. M. Mayor, and stage adaptations of Tartuffe and The Idiot. His original television screenplays include Running Late, After Pilkington, Unnatural Pursuits, and A Month in the Country. His 1971 play Butley, produced by Codron, began a long creative partnership with Harold Pinter as director of both the play and the film versions and continued the partnership with the actor Alan Bates begun with Gray's 1967 television play Death of a Teddy Bear. In all Bates starred in 11 of Gray's works, while Pinter directed 10 separate productions of Gray's works for stage, film, and television, beginning with Butley. The last one was a stage production of The Old Masters, starring Peter Bowles and Edward Fox. As with Butley (1971) and Otherwise Engaged (1975), whose London productions and films both starred Bates, and Quartermaine's Terms (1981), starring Fox, Gray "often returned to the subject of the lives and trials of educated intellectuals." He wrote many other successful stage plays, including The Common Pursuit, The Late Middle Classes, Hidden Laughter, Japes, Close of Play, The Rear Column, and Little Nell, several of which he directed himself. In 1984, at the suggestion of Robert McCrum, Faber editor-in-chief at that time, he kept a diary of the London premiere of The Common Pursuit (directed by Pinter) at the Lyric Hammersmith), resulting in the first of his 8 volumes of theatre-related and personal memoirs, An Unnatural Pursuit (Faber 1985), and culminating in the critically acclaimed trilogy entitled The Smoking Diaries (Granta, 2004–2008). Gray's play about George Blake, Cell Mates (1995), starring Rik Mayall, Stephen Fry and Simon Ward, attracted media attention when Stephen Fry suffered a nervous breakdown and abruptly "fled to Bruges" after the third West End performance, thus leaving the show without