SYDNEY — A Sydney court issued a two-year Apprehended Violence Order against David James Cook, a 63-year-old man, prohibiting him from contacting Norway’s Princess Ingrid Alexandra or her family. The order also bars Cook from entering the University of Sydney campus or searching online for the princess, who has been studying international relations there since arriving in Australia last year.

Apprehended Violence Orders are designed to protect individuals from acts of violence, intimidation, or harassment. Cook appeared in court following concerns over his contact with the princess, who is second in line to the Norwegian throne and the daughter of Crown Prince Haakon and Crown Princess Mette-Marit.

Cook told reporters the order resulted from a card he sent to Princess Ingrid Alexandra. “I sent her a card just asking for friendship, that’s all.” He added, “I did not intentionally upset her in any way and I wouldn’t do so. She’s a nice person. I bumped into her at an event and I followed up with the card.”

After his court appearance, Cook was charged with assaulting a news photographer, according to a police statement. The photographer sustained minor injuries in the incident. Cook was later released from police custody and is scheduled to appear in court on July 17 to face the assault charge.

Princess Ingrid Alexandra recently departed Australia for Norway to visit her mother, who is seriously ill, according to media reports. She had been living on the University of Sydney campus as part of a three-year degree program.

The Apprehended Violence Order explicitly prohibits Cook from any form of communication with the princess or her family, as well as from accessing information about her through digital means. Cook’s appearance in court stemmed from actions that prompted authorities to seek legal protections for the princess during her studies in Australia.