HMV Canada Inc. is set to close all of its stores within a few months after an Ontario Superior Court of Justice approved an application to place the company into receivership.

HUK 10 Ltd., which lent money to the struggling chain, filed the application to the court on Thursday and it was approved on Friday.

It claimed HMV owes it nearly $39 million and it has received no cash payments since November 2014.

HMV would require between $2 million and $5 million annually in cash to stay open, according to court filings, and the company was losing $100,000 a day as customers turned towards online media for their music and videos in recent years.

Senior Justice Geoffrey B. Morawetz approved the application and appointed Gordon Brothers Canada ULC and Merchant Retail Solutions ULC as the agent to sell HMV's remaining merchandise.

Legal documents state that closing stores must cease operations by April 30.

HMV operates 102 stores in Canada and employs about 1,340 people, most of them at its retail locations.