MARGULIES SEALS ‘ER’ EXIT: After a prolonged negotiation to keep her from ankling “ER,” Julianna Margulies is turning down the chance to become one of the highest-paid female actors in TV history, and will ankle at season’s end.

Margulies had been expected to leave what is still TV’s top-rated show once she completes her sixth season, but appeared ready to sign a two-season extension worth about $27 million, after being courted heavily by exec producer John Wells and Warner Bros., which dangled a feature development deal.

Dish hears that after some serious soul-searching, Margulies just gave WB the bitter medicine. Feeling she’s taken her character as far as she can — her Hathaway character gives birth to twins on “ER’s” first Thanksgiving Day nonrerun — Margulies decided to leave all that cash on the table, and walk away to pursue roles in features and theater.

Calling her “an integral member of the ‘ER’ family, Wells gave Margulies a glowing sendoff. “Her talent and commitment have greatly contributed to show’s success,” he said, “and we look forward to working with her throughout the remainder of the season and hopefully sometime in the future. We wish her well and know that she will be successful in all of her endeavors.”

BRUCE BUNCHES UP: Bruce Vilanch will return for his 10th Academy Awards telecast, since he has been named head writer by producers Richard and Lili Fini Zanuck. This time, he might be contending for a golden trophy himself, with the film about his gagman life, “Get Bruce,” being touted for a docu consideration by Miramax.

Vilanch, whose most memorable Oscar contributions were the montage films and theme songs that he collaborated on with Billy Crystal, will continue writing for whoever hosts the next Oscarcast. He might have writer’s cramp with all the writing obligations he’s taking on. He’s been asked by Rosie O’Donnell to be her key writer for the next Tony Awards, and he’s just made a book deal with Putnam to write a collection of witty observations.

He continues as head writer and permanent square on “Hollywood Squares,” and wrote the gags in the current Bette Midler tour, which wraps in Vegas on New Year’s Eve. If that’s not enough, he’ll star in and produce, with his manager Joan Hyler, a one-man show that’s in talks to land Off Broadway at the Westbeth Theatre, where Sandra Bernhard and Eddie Izzard recently performed. Vilanch is repped by William Morris, where Dan Strone made his book deal, and by attorney Stan Coleman and Hyler Management.

WEBER’S HYPHENATING: While Steven Weber’s joined the ensemble cast of the Mike Figgis-directed pic “Time Code,” which has no script, the thesp has moved into the screenwriting game himself. Weber, last seen starring in the TV version of Stephen King’s “The Shining” and in the bigscreen “Jeffrey,” will write “Clubland” for Showtime and Dustin Hoffman’s Punch Prods. Weber will star as well in his tale about father and son talent agents in the late ’50s. Weber’s repped by ICM and AMG.