Just weeks before he killed a Douglas County deputy, prosecutors with the 18th Judicial District decided there wasn't enough evidence to charge Matthew Riehl with a crime after he repeatedly made what some would consider threats to police, and ranted on social media about his issues with law enforcement.

Riehl was killed after shooting several law enforcement officers in an ambush on New Year's Eve, leaving Deputy Zackari Parrish dead.

9Wants to Know has reviewed reports and email between a Douglas County Detective and 18th Judicial District prosecutors about angry emails from the shooter to a Lone Tree Police Officer, Sgt. Scott Vandenberg.

In those reports, a Detective with the Douglas County Sheriff's Office Phil Domenico, wrote twice he didn't believe that charges against Riehl were appropriate. He forwarded his assessment to the prosecutors at the 18th Judicial District, who would make the ultimate decision whether or not to charge Riehl.

Two prosecutors reviewed the case. In an email obtained by 9Wants to Know, Doug Bechtel, Senior Deputy District Attorney wrote, “we do not believe there is likelihood of success at trial. We have to balance the suspect's First Amendment rights with Sgt. (Scott) Vandenberg's rights.”

On November 10, 2017, Riel received a speeding ticket from Sgt. Vandenberg. After Riehl was cited for speeding, he wrote three emails to the officer that some would consider threatening.

“I should have your job,” Riehl wrote in one of those emails. “I'm smarter than you. I have combat proven medical training and I have practiced in Federal court. I want your house. But you can keep your wife and the dog if you have one. You should be terminated for cause and I should be your replacement. I am a more disciplined marksman than your shaking pathetic lying ass.”

18th Judicial District Attorney George Brauchler, a Republican running for Colorado Attorney General, said Riehl's words weren't enough to be concerned threatening behavior.

"The language you read is the most important," Brauchler said. "There is no imminence to that. Then the second part of that statement is not in and of itself a threat. At best, it's veiled."

In America, you get to be "disparaging and critical within some bounds" of public officials, Brauchler said.

According to the documents reviewed by 9Wants to Know, a total of 18 emails were sent by Riehl, 15 to the Lone Tree Municipal Court and 3 to Sgt. Vandenberg.

Riehl also posted videos on YouTube about the Sgt., according to documents obtained by 9Wants to Know. [link to previous story about his online rants]

RELATED: Profanity-laced live stream from ambush shooter shows rambling call to 911

Riehl also sent the Lone Tree Municipal court e-mails demanding the court dismiss his ticket and Sgt. Vandenberg be fired.

The District Attorney's office sent an email explaining why his office would not charge Riehl on December 14, 2017.

"Three e-mails disparaging the conduct of an officer for a ticket he wrote, that is just not going to be something we can turn into a crime in the state of Colorado," Brauchler said. "Here in Colorado, we live in a free society where we not only expect but we encourage people to be critical of public officials when they disagree with them. Now that criticism isn't always polite, it isn't always perfect, but it's going to be something that is given great weight when you look at it in the context of the first amendment."

On December 31, Riehl ambushed and killed Douglas County Deputy Zack Parrish, wounding three of his colleagues and a SWAT officer from Castle Rock Police.

9NEWS talked to George Brauchler, District Attorney for the 18th Judicial District on Saturday about his department's decision not to press charges against Riehl.

“As a member of law enforcement and a member of this community I wish there was something I could think of where there could've been an intervention that could have prevented this horrible outcome,” Brauchler said.

“As a DA, I'm charged with exercising state authority in very limited circumstance, that is when I believe I can prove there has been a violation of Colorado's criminal code and we concluded there was not one here.”

Additionally, less than a month before the deadly shooting on December 5, a member of Douglas County Sheriff's Office Community Response Team and a clinician went to talk to Riehl to see if he needed an “intervention,” according to the report by Detective Domenico.

“After numerous knocks on the door, Matthew finally answered the door,” Domenico wrote. “He asked (Sgt.) Brian (Briggs) if they had a warrant to which Brian replied no. Brian tried to explain that they just wanted to chat with him, but Matthew replied that they had interrupted his movie and proceeded to slam the door.”

DETAILS OF THE REPORT: INVESTIGATION INTO RIEHL

On November 29, 2017, Domenico wrote a report, saying he was instructed to conduct an investigative review that would determine whether criminal charges against Riehl were appropriate. That review came after Riehl called a Lone Tree Police officer named on social media, and sent a number of emails to the Lone Tree Municipal Court.

Sgt. Vandenberg wanted Riehl charged, according to the documents obtained by 9Wants to Know.

Detective Domenico wrote that in the documents he was provided by Lone Tree Police, he didn't see “any threats made by Matthew to harm persons or destroy property. Matthew's tirade is focused on getting his “fake” ticket dismissed and Sgt. Vandenberg terminated.”

Riehl was also able to find where the Sgt. lived. The report was available online.

Even though in his videos, Riehl called the Lone Tree Sgt. names, including “liar,” “serial harasser,” “lying scumbag,” in his report, Detective Domenico wrote Riehl didn't “threaten the person or property of Sgt. Vandenberg.”

“Comments made in the manner they are, do not satisfy the element of Criminal Harassment,” the Detective Domenico wrote in his report. “The comments do not demonstrate an imminent and serious threat to Sgt. Vandenberg's safety.”

November 15, 2017, the detective said Douglas County Sheriff's office Sgt. Brock Bowers went to Riehl's house on a welfare check. After a supervisor at Charles Schwab called the Sheriff's office because a Financial Advisor received emails from Riehl that were “weird” and when the Financial Advisor tried to call Riehl, someone would answer the phone and hang up.

Sgt. Bowers spoke to Riehl through the door, the report said. Riehl refused to let the Sgt. inside. He left.

The Douglas County Sheriff's Detective's report also talks about receiving information from the Lone Tree Police Department, regarding a welfare check they performed on Riehl on June 8, 2017.

Riehl's mother told police that Riehl had a safe that contained weapons, she didn't specify the type or caliber. At the time, Riehl lived with his mother in the basement.

When Lone Tree Police came over, the report says, Riehl would not let them inside the home.

Riehl's mother told them he'd stopped taking medications for his PTSD and bipolar disorder in February of 2017.

Domenico called Riehl a “troubled individual,” but wrote he still didn't believe the comments met the element of “imminent and serious threat to the officer's safety.”

“One could make the argument for harassment,” detective Domenico wrote. “[The emails] are not 'threatening' in nature, but may be construed as annoying. But Sgt. Vandenberg is a public official and Riehl has a right to complain about his government.”

“He has not threatened anyone or anything and from all the information before me, he appears to be functioning at a level that does not demonstrate a grave disability,” Domenico wrote in his report.

“Matthew's behavior and actions to this point, I do not believe have risen to the level of criminal activity.

In a report dated Dec. 6, 2017, Detective Domenico wrote he was asked to review the Riehl's case again and was instructed to document his findings and observations.

Domenico was asked to re-examine the facts of the case and determine whether charges of Attempt to Influence a Public Servant were applicable.

Domenico determined once again that charges against Riehl were not appropriate.

“Merely calling for an individual to be terminated (albeit in a public forum) does not give rise to criminal behavior,” Domenico wrote.

Domenico wrote that to “ensure his due diligence,” he will provide information to the Intake Deputy at the 18th Judicial District Attorney's Office for final decision.

A concrete timeline of when the review of what happened on New Year's Eve will be complete couldn't be given. Brauchler said members of law enforcement who might've "pulled the trigger" and brought down the shooter are still being interviewed.