Knowing about his wife's affair, but acting unaware, Tony and Mark go out for the evening, leaving Margot at the flat. The plan is for Tony to hide a latchkey under the floor mat outside the flat, and let the criminal slip into the apartment unannounced, and murder Margot. Tony plans to phone at the appointed hour to distract Margot while the criminal sneaks up on her.
However, things do not go according to plan. Tony is late with his phone call. The criminal enters the apartment and attacks Margot, but she fights back, stabbing him with the nearby scissors she was using for sewing. Tony then phones and gets a distraught Margot who explains what has happened, the dead criminal lying at her feet.
The police are called and arrest Margot, thinking that she was being blackmailed by the criminal regarding her affair. Margot goes to jail, is sentenced to hang. However, the police later discover an attache case full of money in the flat, money that Tony was planning on paying the criminal to do the deed.
Equally incriminating, the police discover that the latchkey in Margot's handbag does not belong to her but to the criminal. Tony mixed the keys up: the criminal, killed by Margot, had a key in his breast pocket, Tony, assuming it was Margot's flat key, returned it to her handbag. However, it was the criminal's key. Tony admits to his guilt and Margot goes free.
In 1954, Alfred Hitchcock acquired the script and adapted it to the screen, his production starring Grace Kelly as Margot, Ray Milland as Tony and Robert Cummings as the criminal.
Dial M for Murder movie courtesy http://www.imdb.com/title/tt0046912/.