A man was arrested early Wednesday for attempted burglary after he got locked in at a bookstore he was trying to rob in Numazu, Shizuoka Prefecture, and called a friend for help.

Osamu Ito, 24, a car mechanic from the city, entered the bookstore at 11:10 p.m. Tuesday and hid behind a bookshelf waiting for the store to close, police said, alleging he combed the cash register for money after the shop closed.

But Ito was unable to open the locked shutters from inside the pitch-dark bookstore and realized there were no windows or other ways out. He then called a friend on his mobile phone seeking rescue, police said.

Ito was arrested at the scene at 2:45 a.m. Wednesday after the store owner, who was contacted by the burglar's friend, notified police.

"I wanted money," Ito was quoted as saying. Police said they are investigating whether anything was stolen, though only small change was left in the register when the store closed.