I agree with silverfox67 using supplements to help with your digestion and replacing lost good bacteria i.e. taking supplements of acidophilus and adding food enzymes and beano. Attack the root cause of poor digestion.
I addition take ginger capsules and cinnamon capsules,
What is extremely useful is increasing your fibre intake. You can use Psyllium Husk Fibre either in powder or capsule form. Start with a small dosage and gradually increase to the recommended dosage. Also, drink plenty of water. This really helps, give it a try.
Cut out fizzy drinks too and eat high fibre foods in moderation.
You may have an intolerance to wheat products.
Eating natural yogurt is good which contains the enzymes that silverfox67 talks about.
Sometimes flatulence can also be cause by a tummy bug.
Make sure that you wash your hands after using the toilet and before eating food. Wash raw fruit and vegetables before eating them
What foods do you eat I'd leave off onion ,Brussels sprouts , basically hi carbs as they produce flatulence eat two to four slices of bread daily it should help:-)
Try taking acidophilus every morning and see if that helps.
Also, if you don't have enough enzymes to digest your food, it can cause flatulence. You might try getting an acidophilus/enzyme combination. Or try taking Beano before you eat.
Hope this helps.