LOS ANGELES - Larry Hagman died Friday, aged 81, due to complications from his battle with cancer. The actor was best known for his performance as scheming oil baron J.R. Ewing in the television series "Dallas."

Although he first gained fame as nice guy Capt. Tony Nelson on the 1965-1970 NBC comedy "I Dream of Jeannie," Hagman earned his greatest stardom playing J.R. The long-running CBS nighttime soap, about the warring Ewing family, aired from April 1978 to May 1991 and broke viewing records with its "Who Shot J.R.?" 1980 cliff-hanger.

The actor, who returned as J.R. in a new edition of "Dallas" earlier this year, had a long history of health problems, his family said.

"Larry was back in his beloved hometown of Dallas, reenacting the iconic role he loved the most," the family said in a statement. The actor was surrounded by friends and family before he passed peacefully, "just as he'd wished for."

Linda Gray, his "Dallas" costar, was among those with Hagman in his final moments. "He brought joy to everyone he knew. He was creative, generous, funny, loving and talented, and I will miss him enormously," the actress said.

"I can honestly say we've lost not just a great actor, not just a television icon, but an element of pure Americana," added his "I Dream of Jeannie" costar Barbara Eden.