President Donald Trump on Friday praised law enforcement for the quick arrest of pipe bomb suspect Cesar Sayoc Jr. and vowed that he and anyone else possibly involved would be prosecuted to the "fullest extent of the law."

Trump, speaking at the 2018 Young Black Leadership Summit at the White House, called the sending of the bombs a “despicable” act that has “no place in our country” and vowed that “swift and certain justice” would be delivered.

“We must never allow political violence to take root in America. We cannot let it happen. I am committed to do everything in my power as president to stop it and stop it now,” he said.

"Americans must unify. And we must show the world we are united in peace and harmony," he added.

Trump’s comments came less than an hour after authorities said they had taken Sayoc into custody and would charge him in connection with the series of bombs found this week addressed to critics of the president.

The tone of Trump's remarks, and the mood at the event, quickly departed from its sober start and took on a more campaign rally-like feel. At points, Trump appeared to veer off script, repeating previous attacks on Democrats and the media and eliciting cheers from the crowd of young African-American conservatives and supporters in attendance.

Moments after his initial comments, Trump started talking about how people in the audience get attacked for their beliefs, and how he gets attacked too, prompting members of the crowd to shout, "fake news," and "Infowars," the far-right media company belonging to conspiracy theorist Alex Jones. Trump then repeated the term, "fake news."

Later, a person in the audience shouted "Soros" — an apparent reference to billionaire George Soros, who was targeted with one of the pipe bombs earlier in the week — and "lock them up."

Before Trump took the stage at the White House Friday, the crowd chanted "CNN sucks" during comments by Housing and Urban Development Secretary Ben Carson.

Trump, in his speech, also hit Democrats and "globalists," saying that the party "is obsessed with resistance."

In tweets earlier in the day, Trump appeared to suggestthat the timing of the "bomb stuff" was disrupting Republican momentum ahead of the midterm elections. In another tweet Friday, he criticized CNN "and others" for allegedly "blaming" him for the wave of suspicious packages discovered in recent days.

Sayoc is expected to be charged Friday in connection with packages received or intercepted that contained pipe bombs that were addressed to former Vice President Joe Biden, actor Robert De Niro, Rep. Maxine Waters, D-Calif., former Attorney General Eric Holder, former CIA Director John Brennan, former President Barack Obama and former Secretary of State Hillary Clinton.

The package sent to Brennan was addressed to CNN's offices in New York and led to an hours-long evacuation of the building Wednesday. Brennan does not work for CNN, but is a senior national security and intelligence analyst for NBC News and MSNBC.

Two more packages containing explosive devices were discovered Friday, one in Florida addressed to Sen. Cory Booker, D-N.J., and another in New York addressed to former U.S. Director of National Intelligence James Clapper, officials said.

The package mailed to Clapper was addressed to CNN's New York offices, according to a picture obtained by NBC New York, and was discovered at a postal facility in midtown Manhattan.