Bill O'Reilly was fired up Monday night after President Obama vowed to act on his own, through executive actions, to stop the massive influx of illegal immigrants from Central America into the United States. Obama argued that he has wanted to fix the border problem for years, but Democrats cannot get a bill through the House.

'Do Not Travel There': O'Reilly Calls for Boycott of Mexico

Ann Coulter: ‘We Need an Immigration Moratorium’

O'Reilly argued that the president has known about the problems at the Mexican border for five years, asking Juan Williams why the president waited until the situation descended into "chaos" to take action.

O'Reilly pointed back to his interview a few weeks ago with Texas Gov. Rick Perry, who said he personally warned the president in 2010 about these issues and warned the administration about unaccompanied minors coming into Texas in 2012.

Williams argued Perry's warnings have "no relationship to what is going on at the moment," alleging that Perry's claims were for a "political agenda."

Mary Katharine Ham criticized the president for "trashing" Republicans yesterday, saying it's part of a pattern in which he insults House Republicans and then asks for favors.

O'Reilly pointed back to his calls for a boycott of Mexico until something is done about the border crisis, saying just a few days ago U.S. and Mexican authorities carried out a raid on a smuggling operation.

"Oh, just by accident. We couldn't find any other raids, Juan, for the last two years. This is bull, you should know it's bull! They're all lying. They all knew it was happening. They didn't do anything. Now they got caught. Now [he says] 'I'm gonna solve the problem,'" said O'Reilly, adding that it wasn't only his criticism that prompted action.

Williams said the border problems have been worsening for years, reaching a "crescendo" in recent months, and now turning into a "refugee crisis."

"But it didn't have to happen!" O'Reilly fired back.

Ham and O'Reilly agreed that the president acts "reactively" instead of acting "proactively" to solve problems.

Watch the contentious debate above, and check out The Factor, tonight at 8/11p ET to hear Charles Krauthammer's take.

'Kelly File': Border Patrol Agents Called Away From Duties to Babysit

Judge Nap: Obama Using Children As 'Political Pawns'

Boehner Mocks GOP Colleagues on Immigration Reform