Three U.S. soldiers were trapped in an alleged attempted burglary of a medical marijuana dispensary in Colorado Springs, police said.

Darius Thomas, 23, Cory Young, 22, and Ramone Hollins, 22, were arrested on suspicion of second-degree burglary at Rocky Road Remedies, police told The Colorado Springs Gazette. All are active-duty soldiers at Fort Carson.

Police say the men forced open a back door sometime before 2 a.m. Saturday.

When the door closed, they were locked in, said Sgt. Jennifer Lewis.

Officer Alan Vantland spotted the men inside after arriving to check on a complaint at a neighboring bar, she said.

When the burglars saw him, they tried to escape through the front door, but it would not open, Lewis said. The three were trapped until police could free them.

The shop's owner, Renze Waddington, said the burglars were inside for mere minutes before being discovered and didn't have a chance to take anything.

The suspects were booked into the El Paso County jail on $10,000 bail.