CENTENNIAL, Colo. -- Prosecutors in the case of a man suspected of a shooting that left 12 people dead and wounded 59 at a Colorado movie theatre have suffered a setback in obtaining a notebook belonging to the suspect that reportedly contains a violent description of the attack.

The setback came when a judge ruled Thursday that prosecutors couldn't disprove a doctor-patient relationship between suspect James Holmes and a University of Colorado psychiatrist.

Now the question is whether James Holmes, 24, sent the notebook to Dr. Lynne Fenton for use in therapy or treatment. Prosecutors at a hearing Thursday argued that the notebook wasn't meant to be used for those purposes because Holmes wasn't going to be around.

"He intended to be dead or in prison after this shooting," Chief Deputy Karen Pearson said in court. Pearson didn't explain why she believed Holmes would be dead, but she pointed to a dating site where Holmes asked, "Will you visit me in prison?"

Defence attorney Tamara Brady objected to Pearson's argument and said she was making "many gigantic leaps" and that a doctor patient relationship existed even though Fenton hadn't seen Holmes since June 11.

"I'm feeling bad, please stop me. Do something. Help me," Brady said was a possible reason for Holmes sending the notebook to Fenton, adding that prisoners can still be seen by psychiatrists.

Judge William B. Sylvester will take up the matter again at a scheduled hearing on Sept. 20.

"We've got to be extremely cautious about violating privilege," Sylvester said. "If we do, it would be problematic for anything we're trying to do."

Fenton was the prime witness at the hearing where prosecutors sought to gain access to the notebook needed as part of their case.

Defence attorneys say Holmes is mentally ill. Prosecutors suggest Holmes was angry at a failing academic career and efforts to withdraw from a doctoral program at CU.

During questioning, Brady revealed that Holmes reached out to Fenton 9 minutes before the shooting by calling a hospital switchboard that could reach the psychiatrist after business hours. Pearson suggested that Holmes also could have called Fenton's directly at her office, but apparently did not.

Thursday's three-and-a-half-hour hearing was the longest yet that Holmes has attended. He appeared to pay close attention to the proceedings and smiled at least once as he leaned toward his attorney. Holmes had a light moustache but was otherwise clean-shaven, and his hair was blond and orange.

Fenton also testified that she believed they had no doctor-patient relationship by July 19, the day prosecutors say Holmes mailed the notebook. She also said she contacted a campus police officer after her last meeting with Holmes on June 11.

"I communicated with (the officer) to gather more information on this case and also communicate my concerns," Fenton said.

Sylvester, prompted by Brady's objections, barred questions about what those concerns were.

Fenton said she never saw the package. She learned about it from a defence team investigator two days after the shooting and she contacted her attorneys. The package was discovered in a university mailroom July 23.

University spokeswoman Erika Matich said the school would have no comment on Fenton's testimony, including any details about her contact with campus police. A university spokeswoman said last week that a criminal background check was done on Holmes before the attack but released no details.

"Dr. Fenton's testimony stands for itself," Matich said.

Meanwhile, the University of Iowa released records showing it rejected Holmes from a graduate neuroscience program last year after he visited campus for an interview and left the program director bluntly warning colleagues: "Do NOT offer admission under any circumstances."

University spokesman Tom Moore said was academically qualified but officials did not see him as a "good personal fit for our program." He declined to elaborate.

Holmes later enrolled as a first-year Ph.D. student in a neuroscience program at the University of Colorado, Denver. He withdrew June 10.

His rejection from the Iowa school stands in contrast to his previously released application to a similar program at the University of Illinois, where he was offered admission with free tuition and $22,000 (C17,538) per year but declined to enrol.

Holmes said on his Iowa application that he also was applying to Texas A&M, Kansas, Michigan, Alabama and Colorado. He wrote in his Iowa application that he had a thirst for knowledge and wanted to study the "science of learning, cognition and memory."

Holmes added that he was passionate about neuroscience and would bring "my strong moral upbringing" to the program.