I have this problem with fruit flies in the compost bin too! Even in this cold weather they are flourishing!! I have tried all sorts of things. I NEVER EVER put in anything cooked - that includes cooked fruit and veg. Somebody told me not to put potato peelings in so i tried that too, but nothing has worked for me yet. My bin, fortunately, is round the corner from the kitchen so I don't have too much bother with them coming in, but when I take the lid off to put something in I have to cover my face as they just swarm out. I'd love to get rid of them too.