TORONTO - Canada's ban on marijuana was effectively upheld Friday when Ontario's top court struck down an earlier court decision that said Canada's laws related to medicinal pot were unconstitutional.

In overturning the lower court ruling, the Court of Appeal ruled the trial judge had made numerous errors in striking down the country's medical pot laws.

Among other things, the Appeal Court found the judge was wrong to interpret an earlier ruling as creating a constitutional right to use medical marijuana.

"Given that marijuana can medically benefit some individuals, a blanket criminal prohibition on its use is unconstitutional," the Appeal Court said.

"(However), this court did not hold that serious illness gives rise to an automatic right to use marijuana."

Currently, doctors are allowed to exempt patients from the ban on marijuana, but many physicians have refused to prescribe the drug on the grounds its benefits are not scientifically proven.

The Canadian HIV/AIDS Legal Network called the decision a disappointing missed opportunity.

"Allowing the current regulations to stand unchanged will leave many people with serious health conditions without effective access to legal authorization to use cannabis as medicine," said Richard Elliott, executive director of the network.

"People shouldn't have to risk going to prison in order to get the medicine they need."

The ruling comes in the case of Matthew Mernagh, 37, of St. Catharines, Ont., who suffers from fibromyalgia, scoliosis, seizures and depression.

While he argues marijuana is the most effective treatment of his pain, he said he was unable to find a doctor to support his application for a medical marijuana licence.

Mernagh resorted to growing his own and was charged with producing the drug in April 2008.

In April 2011, Ontario Superior Court Justice Donald Taliano found that sick people cannot get access to medical marijuana through appropriate means. He said that forced ill people who should be able to get the drugs to resort to criminal acts.

Taliano struck down the laws prohibiting possession and production of cannabis as unconstitutional but the ruling was put on hold pending the federal government's appeal, which was heard last May.

The Appeal Court found Taliano had relied on "anecdotal evidence" and drew unfounded conclusions that the medicinal pot scheme made it almost impossible for patients to get legal access to the drug.

"The trial judge found that the 'vast majority' of those who needed medical marijuana were unable to get physicians to sign (exemption) declarations," the Appeal Court said.

"The record does not support the trial judge's inference that they failed to obtain medical declarations only because Canadian physicians are boycotting the (medicinal pot scheme)."

Osgoode Law Prof. Alan Young said the Appeal Court decision should not be seen as an endorsement of the medical marijuana program.

"They simply didn't feel the evidence was sufficient," Young said. "The case is important to show people that the program is still failing."

He noted the court started off in its judgment by noting this was the third time the Appeal Court was reviewing the medicinal pot scheme and the government was already making changes.

In December, Health Minister Leona Aglukkaq announced Ottawa would no longer grant medical marijuana licences to users, and only doctors would be able to prescribe pot.

In Friday's decision, the court said Mernagh had failed to provide evidence from a doctor that he met the criteria for a medical exemption to the country's pot ban.

"It was not open to the trial judge to hold that Mr. Mernagh and the patient witnesses who had not obtained medical declarations were entitled to exemptions," the Appeal Court said.

Note to readers: This is a corrected story. An earlier version said the top court struck down the country's laws related to medicinal pot.

Related on HuffPost:

Loading Slideshow...
  • Asiatic Exclusion League Riot in Vancouver

    1907: An <a href="">anti-Asian riot by the Asiatic Exclusion League</a> tears through Vancouver's Chinatown.

  • Opium and Narcotic Drug Act

    1911: After William Lyon MacKenzie King's Opium Act of 1908, Vancouver's chief of police supports the <a href="">Opium and Narcotic Drug Act</a>, which prohibits the use of opium, cocaine or morphine.

  • Cannabis added to Opium and Narcotics Drug Act

    1923: <a href="">Cannabis is added</a> to the Opium and Narcotics Drug Act.

  • Controlled Drugs and Substances Act

    1996: Jean Chretien's Liberal government passes the <a href="">Controlled Drugs and Substances Act</a>, which imposes a maximum three-year jail sentence and a $5,000 fine for any contraventions.

  • Bill C-38

    2002: Urged on by Justice Minister Martin Cauchon, the Liberal government, tries to push through <a href="">Bill C-38</a>, an act to amend the Controlled Drugs and Substances Act and other legislation to permit possession of marijuana with only a fine as punishment. The bill died during prorogation.

  • Marc Emery

    2010: Vancouver pro-pot activist <a href="">Marc Emery</a> (seen on the poster) is extradited to the United States to face drug charges relating to his seed-selling business.

  • InSite

    2011: The Supreme Court of Canada rules that <a href="">InSite</a>, a safe injection facility on the Downtown Eastside, can continue to provide services for addicts.

  • Stephen Harper

    2012: Conservative government under Prime Minister Stephen Harper passes an omnibus crime bill with <a href="">mandatory minimum sentences</a> for possession of marijuana.

  • Dana Larsen

    2012: Activist <a href="">Dana Larsen</a> starts an initiative petition in B.C. to stop police from enforcing simple possession-and-use laws for adults. He later <a href="">withdraws the petition</a>, saying he wants more time to organize volunteers.

  • Washington State legalizes marijuana

    2012: Washington state legalizes recreational use of marijuana as part after a referendum passes during the U.S. presidential election. Supporters include travel guide author Rick Steves.