HALIFAX -- A medical student at Dalhousie University who allegedly told his psychiatrist he had thoughts of shooting up to 20 people before killing himself has been charged with sexual assault in a separate incident.

A spokeswoman for Nova Scotia's public prosecution service says the charge was laid against Stephen Gregory Tynes in Halifax provincial court on Wednesday morning.

Chris Hansen said the sexual assault charge is unrelated to the other incidents.

The 30-year-old is pleading not guilty to two counts of uttering threats to cause bodily harm and one count of engaging in threatening conduct in a trial set for June 6.

He is also pleading not guilty to a charge of unauthorized possession of a prohibited device in relation to an overcapacity cartridge magazine.

A police search warrant in those matters alleges Tynes told his psychiatrist he was going to stab the associate dean of undergraduate medical education at Dalhousie as well as her daughter.

Tynes, whose lawyer appeared on his behalf on Wednesday, is due in court on May 3 for election and plea in the sexual assault charge.