A Texas Republican congressman said Thursday he will not seek re-election to Congress after a nude photo and lewd text messages between him and multiple women surfaced.

"I am announcing today that I will not seek reelection in 2018,” Rep. Joe Barton said in a Thursday statement. “To the people of the 6th District, thank you for your support and friendship."

Before the messages were made public, Barton had said he planned to run for an 18th term to the House.

But this week, another woman released online messages allegedly showing Barton steering the conversation toward sexual themes.

Kelly Canon, a Tea Party organizer in the Dallas suburb of Arlington, released a series of Facebook Messenger conversations with Barton from 2012 in which he asked things like if she was wearing panties.

First reported by the Fort Worth Star-Telegram on Wednesday, the revelation comes a week after Barton apologized for a nude photo of him that circulated on social media.

Canon later told The Associated Press that she and Barton exchanged online messages from around 2011 to 2015. They included Barton asking after midnight in June 2012 whether Canon was "wearing a tank top only ... and no panties." The congressman was married at the time to his second wife but is now twice divorced.

Barton told The Dallas Morning News on Thursday that people “lost faith” in him over the situation.

"There are enough people who lost faith in me that it’s time to step aside and let there be a new voice for the 6th district in Washington, so I am not going to run for re-election," Barton said.

REPUBLICANS WHO WON’T BE COMING BACK TO CONGRESS AFTER 2018 MIDTERM ELECTIONS

It began when an anonymous account on Twitter last week posted a censored photo of a nude man and suggested it was Barton. The account also tweeted a screenshot of a text message from "Joe B" using strongly sexual language.

Barton apologized and suggested the photo was taken while he was separated from his wife and had consensual relationships with other women.

"While separated from my second wife, prior to the divorce, I had sexual relationships with other mature adult women," Barton said. "Each was consensual. Those relationships have ended.”

Some have defended Barton, calling him a victim of “revenge porn.” The congressman said last week the Capitol Police offered to launch an investigation into the release and he accepted the offer.

Barton, who was first elected to Congress in 1984, is the vice-chairman of the House Energy and Commerce Committee.

Congress is dealing with several other sex scandals, including Michigan Democratic Rep. John Conyers facing allegations of making unwanted advances toward staffers and Minnesota Sen. Al Franken apologizing after several women have accused him of harassment.

Fox News’ Jason Donner and The Associated Press contributed to this report.