Former Illinois Congressman turned conservative radio host Joe Walsh went on a twitter rant following the deadly sniper attack on Dallas police officers Thursday, including a now-deleted message that read: "This is now war. Watch out Obama."

Walsh, a Republican who represented Illinois' 8th district from 2011 to 2013 before becoming a syndicated radio host, delivered a series of tweets that criticized President Barack Obama and suggested that the president was a "cop hater" no different from "the thugs on the street."

In another tweet, Walsh suggested that the president's rhetoric about recent police shootings of unarmed African American men might have led to the sniper attack, which killed four Dallas officers and injured seven others and one civilian.

Also Read:Snipers Kill 4 Police During Rally to Protest Police Shootings, 7 Officers Injured

"Obama says Cops are racist so 2 uneducated black thugs shoot 10 Dallas Cops," he wrote.

See photos of the scene of attack:



31 PHOTOS Officers killed at Dallas protest after police killings of two black men See Gallery Officers killed at Dallas protest after police killings of two black men DALLAS, TX - JULY 7: Dallas police stand near the scene where four Dallas police officers were shot and killed on July 7, 2016 in Dallas, Texas. According to reports, shots were fired during a protest being held in downtown Dallas in response to recent fatal shootings of two black men by police - Alton Sterling on July 5, 2016 in Baton Rouge, Louisiana and Philando Castile on July 6, 2016, in Falcon Heights, Minnesota. (Photo by Ron Jenkins/Getty Images) DALLAS, TX - JULY 7: Dallas police stand watch near the scene where four Dallas police officers were shot and killed on July 7, 2016 in Dallas, Texas. According to reports, shots were fired during a protest being held in downtown Dallas in response to recent fatal shootings of two black men by police - Alton Sterling on July 5, 2016 in Baton Rouge, Louisiana and Philando Castile on July 6, 2016, in Falcon Heights, Minnesota. (Photo by Ron Jenkins/Getty Images) DALLAS, TX - JULY 7: Dallas residents sit near the scene where four Dallas police officers were shot and killed on July 7, 2016 in Dallas, Texas. According to reports, shots were fired during a protest being held in downtown Dallas in response to recent fatal shootings of two black men by police - Alton Sterling on July 5, 2016 in Baton Rouge, Louisiana and Philando Castile on July 6, 2016, in Falcon Heights, Minnesota. (Photo by Ron Jenkins/Getty Images) DALLAS, TX - JULY 7: Dallas police and residents stand near the scene where four Dallas police officers were shot and killed on July 7, 2016 in Dallas, Texas. According to reports, shots were fired during a protest being held in downtown Dallas in response to recent fatal shootings of two black men by police - Alton Sterling on July 5, 2016 in Baton Rouge, Louisiana and Philando Castile on July 6, 2016, in Falcon Heights, Minnesota. (Photo by Ron Jenkins/Getty Images) DALLAS, TX - JULY 7: Dallas residents stand near the scene where four Dallas police officers were shot and killed on July 7, 2016 in Dallas, Texas. According to reports, shots were fired during a protest being held in downtown Dallas in response to recent fatal shootings of two black men by police - Alton Sterling on July 5, 2016 in Baton Rouge, Louisiana and Philando Castile on July 6, 2016, in Falcon Heights, Minnesota. (Photo by Ron Jenkins/Getty Images) Police attempt to calm the crowd as someone is arrested following the sniper shooting in Dallas on July 7, 2016. A fourth police officer was killed and two suspected snipers were in custody after a protest late Thursday against police brutality in Dallas, authorities said. One suspect had turned himself in and another who was in a shootout with SWAT officers was also in custody, the Dallas Police Department tweeted. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) A Police officer stands guard at a baracade following the sniper shooting in Dallas on July 7, 2016. A fourth police officer was killed and two suspected snipers were in custody after a protest late Thursday against police brutality in Dallas, authorities said. One suspect had turned himself in and another who was in a shootout with SWAT officers was also in custody, the Dallas Police Department tweeted. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) Protestors yell after police officers arrest a bystander following the shooting at a protest in Dallas on July 7, 2016. A fourth police officer was killed and two suspected snipers were in custody after a protest late Thursday against police brutality in Dallas, authorities said. One suspect had turned himself in and another who was in a shootout with SWAT officers was also in custody, the Dallas Police Department tweeted. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) Police attempt to calm the crowd as someone is arrested following the sniper shooting in Dallas on July 7, 2016. A fourth police officer was killed and two suspected snipers were in custody after a protest late Thursday against police brutality in Dallas, authorities said. One suspect had turned himself in and another who was in a shootout with SWAT officers was also in custody, the Dallas Police Department tweeted. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) Protestors yell after police officers arrest a bystander following the shooting at a protest in Dallas on July 7, 2016. A fourth police officer was killed and two suspected snipers were in custody after a protest late Thursday against police brutality in Dallas, authorities said. One suspect had turned himself in and another who was in a shootout with SWAT officers was also in custody, the Dallas Police Department tweeted. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) Protestors yell after police officers arrest a bystander following the shooting at a protest in Dallas on July 7, 2016. A fourth police officer was killed and two suspected snipers were in custody after a protest late Thursday against police brutality in Dallas, authorities said. One suspect had turned himself in and another who was in a shootout with SWAT officers was also in custody, the Dallas Police Department tweeted. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) A police officer tries to calm protestors following the sniper shooting in Dallas on July 7, 2016. A fourth police officer was killed and two suspected snipers were in custody after a protest late Thursday against police brutality in Dallas, authorities said. One suspect had turned himself in and another who was in a shootout with SWAT officers was also in custody, the Dallas Police Department tweeted. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) A police officer tries to calm protestors following the sniper shooting in Dallas on July 7, 2016. A fourth police officer was killed and two suspected snipers were in custody after a protest late Thursday against police brutality in Dallas, authorities said. One suspect had turned himself in and another who was in a shootout with SWAT officers was also in custody, the Dallas Police Department tweeted. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) Police attempt to calm the crowd as someone is arrested following the sniper shooting in Dallas on July 7, 2016. A fourth police officer was killed and two suspected snipers were in custody after a protest late Thursday against police brutality in Dallas, authorities said. One suspect had turned himself in and another who was in a shootout with SWAT officers was also in custody, the Dallas Police Department tweeted. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) Police cars sit on Main Street in Dallas following the sniper shooting during a protest on July 7, 2016. A fourth police officer was killed and two suspected snipers were in custody after a protest late Thursday against police brutality in Dallas, authorities said. One suspect had turned himself in and another who was in a shootout with SWAT officers was also in custody, the Dallas Police Department tweeted. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) Tonight it appears that two snipers shot ten police officers from elevated positions during the protest/rally.... https://t.co/JzHhoMzF5k With heavy hearts, we are devastated to report a fourth officer has been killed. 2 snipers kill 3 police officers, wound 7 others in Dallas during protest. https://t.co/mm44qKgE40 (Photo: AP) https://t.co/DyaCmJRd2n People rally in Dallas, Texas, on Thursday, July 7, 2016 to protest the deaths of Alton Sterling and Philando Castile. Black motorist Philando Castile, 32, a school cafeteria worker, was shot at close range by a Minnesota cop and seen bleeding to death in a graphic video shot by his girlfriend that went viral Thursday, the second fatal police shooting to rock America in as many days. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) People rally in Dallas, Texas, on Thursday, July 7, 2016 to protest the deaths of Alton Sterling and Philando Castile. Black motorist Philando Castile, 32, a school cafeteria worker, was shot at close range by a Minnesota cop and seen bleeding to death in a graphic video shot by his girlfriend that went viral Thursday, the second fatal police shooting to rock America in as many days. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) People rally in Dallas, Texas, on Thursday, July 7, 2016 to protest the deaths of Alton Sterling and Philando Castile. Black motorist Philando Castile, 32, a school cafeteria worker, was shot at close range by a Minnesota cop and seen bleeding to death in a graphic video shot by his girlfriend that went viral Thursday, the second fatal police shooting to rock America in as many days. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) A man holds a bat reading 'Black Power' during a protest in Dallas, Texas, on Thursday, July 7, 2016 to protest the deaths of Alton Sterling and Philando Castile. Black motorist Philando Castile, 32, a school cafeteria worker, was shot at close range by a Minnesota cop and seen bleeding to death in a graphic video shot by his girlfriend that went viral Thursday, the second fatal police shooting to rock America in as many days. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) A man lays on the ground after yelling 'Don't shoot me' at police during a rally in Dallas, Texas, on Thursday, July 7, 2016 to protest the deaths of Alton Sterling and Philando Castile. Black motorist Philando Castile, 32, a school cafeteria worker, was shot at close range by a Minnesota cop and seen bleeding to death in a graphic video shot by his girlfriend that went viral Thursday, the second fatal police shooting to rock America in as many days. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) People rally in Dallas, Texas, on Thursday, July 7, 2016 to protest the deaths of Alton Sterling and Philando Castile. Black motorist Philando Castile, 32, a school cafeteria worker, was shot at close range by a Minnesota cop and seen bleeding to death in a graphic video shot by his girlfriend that went viral Thursday, the second fatal police shooting to rock America in as many days. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) A woman takes pictures of the rally in Dallas, Texas, on Thursday, July 7, 2016 to protest the deaths of Alton Sterling and Philando Castile. Black motorist Philando Castile, 32, a school cafeteria worker, was shot at close range by a Minnesota cop and seen bleeding to death in a graphic video shot by his girlfriend that went viral Thursday, the second fatal police shooting to rock America in as many days. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) People rally in Dallas, Texas, on Thursday, July 7, 2016 to protest the deaths of Alton Sterling and Philando Castile. Black motorist Philando Castile, 32, a school cafeteria worker, was shot at close range by a Minnesota cop and seen bleeding to death in a graphic video shot by his girlfriend that went viral Thursday, the second fatal police shooting to rock America in as many days. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) People rally in Dallas, Texas, on Thursday, July 7, 2016 to protest the deaths of Alton Sterling and Philando Castile. Black motorist Philando Castile, 32, a school cafeteria worker, was shot at close range by a Minnesota cop and seen bleeding to death in a graphic video shot by his girlfriend that went viral Thursday, the second fatal police shooting to rock America in as many days. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) People rally in Dallas, Texas, on Thursday, July 7, 2016 to protest the deaths of Alton Sterling and Philando Castile. Black motorist Philando Castile, 32, a school cafeteria worker, was shot at close range by a Minnesota cop and seen bleeding to death in a graphic video shot by his girlfriend that went viral Thursday, the second fatal police shooting to rock America in as many days. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) People rally in Dallas, Texas, on Thursday, July 7, 2016 to protest the deaths of Alton Sterling and Philando Castile. Black motorist Philando Castile, 32, a school cafeteria worker, was shot at close range by a Minnesota cop and seen bleeding to death in a graphic video shot by his girlfriend that went viral Thursday, the second fatal police shooting to rock America in as many days. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) People rally in Dallas, Texas, on Thursday, July 7, 2016 to protest the deaths of Alton Sterling and Philando Castile. Black motorist Philando Castile, 32, a school cafeteria worker, was shot at close range by a Minnesota cop and seen bleeding to death in a graphic video shot by his girlfriend that went viral Thursday, the second fatal police shooting to rock America in as many days. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) People rally in Dallas, Texas, on July 7, 2016 to protest the deaths of Alton Sterling and Philando Castile. Black motorist Philando Castile, 32, a school cafeteria worker, was shot at close range by a Minnesota cop and seen bleeding to death in a graphic video shot by his girlfriend that went viral Thursday, the second fatal police shooting to rock America in as many days. / AFP / Laura Buckman (Photo credit should read LAURA BUCKMAN/AFP/Getty Images) Up Next See Gallery Discover More Like This HIDE CAPTION SHOW CAPTION of SEE ALL BACK TO SLIDE

Walsh became a trending topic on Twitter Thursday night, with much of the focus on a tweet that he quickly deleted.

"3 Dallas Cops killed, 7 wounded," he wrote. "This is now war. Watch out Obama. Watch out black lives matter punks. Real America is coming after you."

Also Read:Obama Sounds Off on Police Shootings: 'All of Us as Americans Should Be Troubled'

In a later tweet, Walsh tried to distance himself from his earlier, more provocative language.

"I wasn't calling for violence, against Obama or anyone," he wrote. "Obama's words & BLM's deeds have gotten cops killed. Time for us to defend our cops."

Read the tweets below:

Joe Walsh deleted his tweet. Here's the screenshot: pic.twitter.com/t5ke5YWxbu — Kyle Griffin (@kylegriffin1) July 8, 2016

4 Dallas Cops assassinated tonight.



Blacks lives matter cheers.



LGBT blames Christians.



Obama defends Islam. — Joe Walsh (@WalshFreedom) July 8, 2016

Obama says Cops are racist so 2 uneducated black thugs shoot 10 Dallas Cops tonight, killing 4.



Wake up silent majority. Stand w our Cops. — Joe Walsh (@WalshFreedom) July 8, 2016

It's time 4 patriotic Americans to stand up & stand against all the Cop haters - from Obama to the thugs on the street.



It's way past time. — Joe Walsh (@WalshFreedom) July 8, 2016

I wasn't calling for violence, against Obama or anyone. Obama's words & BLM's deeds have gotten cops killed. Time for us to defend our cops. — Joe Walsh (@WalshFreedom) July 8, 2016

Read original story Former Congressman Joe Walsh Tells 'Cop Hater' Obama to 'Watch Out': 'This Is Now War' At TheWrap