The Saw actor will join Natalie Portman and Ashton Kutcher in the Paramount project, reports Variety.
The movie centres on a couple of friends (Portman and Kutcher) who embark on a physical relationship with no intention of falling in love or starting a long-term romance.
Elwes will play a doctor who works alongside and develops a flirtatious relationship with Portman's role.
Olivia Thirlby, Kevin Kline and Greta Gerwig have also been cast in the film.
The still-untitled picture is scheduled to open January 7, 2011 in US cinemas.
Elwes is further returning to the Saw horror franchise for the upcoming Saw VII 3D.