MANSFIELD, TX - APRIL 13: Rep. Joe Barton (R-TX) answers a question during a town hall meeting at Mansfield City Hall on April 13, 2017 in Mansfield, Texas. A capacity crowd filled the Mansfield City Hall counsel chambers where attendees expressed disapproval with the Republican's handling of health care, term limits and the failure of Donald Trump to release his taxes. (Photo by Mike Stone/Getty Images)
Mike Stone/Getty Images
MANSFIELD, TX - APRIL 13: Rep. Joe Barton (R-TX) answers a question during a town hall meeting at Mansfield City Hall on April 13, 2017 in Mansfield, Texas. A capacity crowd filled the Mansfield City Hall counsel chambers where attendees expressed disapproval with the Republican's handling of health care, term limits and the failure of Donald Trump to release his taxes. (Photo by Mike Stone/Getty Images)
Now playing
01:25
Nude photo goes viral, congressman apologizes
Garret Ventry
Now playing
01:33
GOP adviser abruptly quits amid sex harassment claim
Getty Images
Now playing
01:49
Trump defends Kavanaugh amid allegations
WASHINGTON, DC - APRIL 21:  Rep. Chris Collins (R-NY) talks to reporters following a meeting with fellow members of Congress and representatives from the Donald Trump presidential campaign at the National Republican Club of Capitol Hill April 21, 2016 in Washington, DC. (Chip Somodevilla/Getty Images)
Chip Somodevilla/Getty Images
WASHINGTON, DC - APRIL 21: Rep. Chris Collins (R-NY) talks to reporters following a meeting with fellow members of Congress and representatives from the Donald Trump presidential campaign at the National Republican Club of Capitol Hill April 21, 2016 in Washington, DC. (Chip Somodevilla/Getty Images)
Now playing
02:34
GOP lawmaker indicted for insider trading
SAN DIEGO, CA - AUGUST 23: Rep. Duncan Hunter (R-CA) walks into the Federal Courthouse for an arraignment hearing on August 23, 2018 in San Diego, California. Hunter and his wife Margaret are accused of using more than $250,000 in campaign funds for personal use. (Photo by Sandy Huffaker/Getty Images)
Sandy Huffaker/Getty Images North America/Getty Images
SAN DIEGO, CA - AUGUST 23: Rep. Duncan Hunter (R-CA) walks into the Federal Courthouse for an arraignment hearing on August 23, 2018 in San Diego, California. Hunter and his wife Margaret are accused of using more than $250,000 in campaign funds for personal use. (Photo by Sandy Huffaker/Getty Images)
Now playing
03:19
GOP lawmaker blames wife in corruption case
Now playing
01:50
State Rep. resigns after screaming N-word
Rep. Jason Lewis
Now playing
02:53
GOP rep. defends prior comments on 'slut' women
In this Jan. 29, 2018, file photo, Missouri Gov. Eric Greitens speaks in Palmyra, Mo.
Jeff Roberson/AP
In this Jan. 29, 2018, file photo, Missouri Gov. Eric Greitens speaks in Palmyra, Mo.
Now playing
02:29
Missouri Gov. Eric Greitens indicted
 Eric Greitens Founder and CEO, The Mission Continues speaks at the Robin Hood Veterans Summit at Intrepid Sea-Air-Space Museum on May 7, 2012 in New York City.
Getty Images
Eric Greitens Founder and CEO, The Mission Continues speaks at the Robin Hood Veterans Summit at Intrepid Sea-Air-Space Museum on May 7, 2012 in New York City.
Now playing
00:44
Governor admits affair, denies blackmail
Now playing
02:22
Sex scandals in Washington through the years
Megan Barry
WZTV
Megan Barry
Now playing
01:11
Mayor admits affair with head of her security
 The White House is shown during departure by President Donald Trump for the congressional Gold Medal ceremony for former Senate Majority Leader Bob Dole at the U.S. Capitol January 17, 2018 in Washington D.C. (Al Drago-Pool/Getty Images)
Pool/Getty Images
The White House is shown during departure by President Donald Trump for the congressional Gold Medal ceremony for former Senate Majority Leader Bob Dole at the U.S. Capitol January 17, 2018 in Washington D.C. (Al Drago-Pool/Getty Images)
Now playing
00:51
Second WH aide resigns after abuse accusations
UNITED STATES - DECEMBER 13: Rep. Blake Farenthold, R-Texas, attends a House Judiciary Committee hearing in Rayburn Building on the Justice Department's investigation of Russia's interference in the 2016 election featuring testimony by Deputy Attorney General Rod Rosenstein on December 13, 2017. (Photo By Tom Williams/CQ Roll Call) (CQ Roll Call via AP Images)
Tom Williams/AP
UNITED STATES - DECEMBER 13: Rep. Blake Farenthold, R-Texas, attends a House Judiciary Committee hearing in Rayburn Building on the Justice Department's investigation of Russia's interference in the 2016 election featuring testimony by Deputy Attorney General Rod Rosenstein on December 13, 2017. (Photo By Tom Williams/CQ Roll Call) (CQ Roll Call via AP Images)
Now playing
01:30
Ex-Farenthold aide felt pressured, source says
Now playing
01:02
Congressman calls female colleagues 'eye candy'
Former Congressman Anthony Weiner (D-N.Y.), center, leaves federal court following his sentencing, Monday, Sept. 25, 2017, in New York. Weiner was sentenced to 21 months in a sexting case that rocked the presidential race.
Mark Lennihan/AP
Former Congressman Anthony Weiner (D-N.Y.), center, leaves federal court following his sentencing, Monday, Sept. 25, 2017, in New York. Weiner was sentenced to 21 months in a sexting case that rocked the presidential race.
Now playing
01:04
A timeline of Anthony Weiner's sexting scandals
Pool
Now playing
00:56
Boy demands apology from Mike Pence

Story highlights

Barton's statement does not mention the nude photo of him that surfaced earlier this month

Last week, Barton apologized for not using "better judgment"

Washington CNN —  

Joe Barton, the Republican Texas congressman who found himself in hot water after a nude photo of him surfaced online, will not seek re-election, Barton’s office confirmed to CNN Thursday.

In a statement, Barton wrote, “I am announcing today that I will not seek re-election in 2018. To the people of the 6th District, thank you for your support and friendship.”

The statement added that while Barton has been very proud of his “public record and the many accomplishments,” it is “time to step aside and let there be a new voice.”

Barton’s message did not mention the fallout from the nude image revelation. The photo surfaced last week from an anonymous Twitter account. Sarah Dodd of Dodd Communications, who is helping Barton respond to the image, confirmed to CNN that the photo is of him.

Last week, Barton apologized for not using “better judgment” while separated from his wife and in consensual relationships with women. Dodd told CNN that Barton did not release the image himself and does not know who did.

“It’s really a violation of his privacy,” she said.

Barton, the longest serving member of the Texas House delegation, had previously announced plans to seek re-election to Congress earlier this month.

CNN’s Juanna Summers and MJ Lee contributed to this report.