EAST ATLANTIC BEACH - An East Atlantic Beach man suffered an electrical shock and went into cardiac arrest while trying to hang a flag Saturday afternoon, police say.

The 27-year-old victim was trying to hang a flag across Buffalo Avenue when it got stuck on an electrical wire, police say.

He reportedly attempted to take the flag down using a metal pole and was shocked while standing on his second-story porch.

After he fell to the ground, witnesses gave him CPR and called 911, police say.

The man is in critical but stable condition at a local hospital, according to officials.