DENVER — A man who testified as a DNA expert in the Casey Anthony trial in Florida and helped overturn the murder conviction of a Colorado man wasn’t allowed to testify at a trial in Denver this week after being discredited, Denver prosecutors said Thursday.

The Denver District Attorney’s Office said Judge Brian Whitney barred Richard Eikelenboom from testifying at a sex assault trial after he admitted he had no direct DNA extraction or analysis experience, that his lab was not accredited in the United States, that he failed basic proficiency tests in 2011 and 2012 and that he admitted he was “self-trained” in running DNA profiles.

“I appreciate Judge Whitney recognizing that Mr. Eikelenboom’s opinions about DNA have no basis in science and that he was not qualified to testify as an expert,” District Attorney Mitch Morrissey said in a statement.

Eikelenboom could not be reached to comment because his phone rang unanswered and did not accept messages.

But he told KMGH-TV (http://bit.ly/2bNynpP) that he has been accredited in the Netherlands and received U.S. accreditation on Monday by the American Society of Crime Lab Directors the same day he was questioned by the prosecutor.

“I would not get that if I was not a solid scientist,” he said.

Eikelenboom was called to testify in the trial of two men who were convicted Wednesday of sexually assaulting a 22-year-old woman in 2013. He told KMGH-TV that the defense lawyers were not well prepared and the prosecutor questioning him did not allow him fully answer questions.

The ruling isn’t expected to affect previous cases, but experts say it could make it harder for Eikelenboom to be qualified as an expert in other trials.

“It’s going to be an issue that will haunt him for quite some time,” said Dan Krane, a DNA expert at Wright State University in Dayton, Ohio.

Eikelenboom’s DNA tests helped overturn the conviction and life sentence of Timothy Masters in the 1987 slaying of Peggy Hettrick in Fort Collins.

Masters, freed in January 2008, was the first person in Colorado released from prison because of DNA evidence. Hettrick’s slaying remains unsolved.

Masters’ attorney, David Lane, said it is not unusual for the competence of expert witnesses to be questioned.

“The district attorney said there was no evidence,” Lane said. “The DNA expert confirmed what the district attorney said. It wasn’t critical, but it was very important.”