Politically charged rhetoric directed at President Trump is hurting his ability to help heal the pain of communities reeling from mass shootings, according to Rudy Giuliani.

Trump is acting in the same capacity as former President George W. Bush did when he visited Manhattan after the 9/11 attacks, Giuliani said Wednesday on "The Ingraham Angle."

"It's very sad for our country that they're doing this," the former New York City mayor said of critical rhetoric against the president.

"I remember what it meant to New York when President Bush came here four days later. It lifted everyone's spirits -- they felt like the country was behind them," Giuliani said.

MASS SHOOTINGS BRING TRUMP TO DAYTON, EL PASO AMID PROTESTS

Giuliani, who now serves as a personal attorney to President Trump, said the president is "just trying to heal some of the pain these people are going through" in El Paso, Texas, and Dayton, Ohio.

However, he also warned the president's critics who were politicizing Trump's response that doing so could backfire on them in the long run.

"Politically, this doesn't play. This is very, very partisan," he said. "I think most of the American people can see through this. It is a shame these people have degraded themselves to this level -- to do this kind of thing, it's really shameful."

CLICK HERE TO GET THE FOX NEWS APP

In Texas, the president was greeted at the airport by the state's Republican governor, Greg Abbott, as well as Sens. John Cornyn, R-Texas, and Ted Cruz, R-Texas, and El Paso Mayor Dee Margo -- who bucked Democrats' calls on Monday to turn the president away.

As happened earlier Wednesday in Dayton, Ohio, scene of another lethal mass shooting last weekend, Trump was greeted by protesters demanding tougher anti-gun laws and an end to caustic rhetoric — including some from the president — that they believed to be contributing to a culture of violence in America.

On the whole, however, reaction to Trump's visits was welcoming -- and, according to MSNBC correspondent Jacob Soboroff, "surprisingly positive."

Fox News' Adam Shaw and Gregg Re contributed to this report.