A cat may be partially effective or small live traps can be used. Raccoons den in hollow trees, ground burrows, brush piles, barns and abandoned buildings, dense clumps of cattail, or rock crevices. Raccoons are especially attracted to sweet corn and seem to know exactly when the corn is ready to eat. Ears will be bent down or torn off the stalk for feeding. Husks will almost be removed and some of the kernels will be eaten.
Raccoons also like strawberries and blueberries.
Since they can climb, fences must have a bend one foot outward, or you can add a single electrified wire on top of the fence. When raccoons walk on the crystals, they get some on their paws. When they eat, they associate the unpleasant taste with the corn, and learn to avoid it. Re-sprinkle the crystals after each rain. With a little effort you should be able to piece together the puzzle, and then take action to solve your problem.