Id 99% say thats its Cammalanus. An intestinal worm which needs to be treated with Levamisole. Go to your local vet and ask if they have any Aviverm, as it is levamisole mainly.
If its the 22% levamisole one then use 1ml per 24Ls (IIRC) You first need to do a 90% water change, making sure that you gravel syphon hard out, and get as much of the crap out from the bottom, as that is where the baby worms live. Then fill the tank up and treat withe the correct amount. better to overdose than underdose. Levamisole will not harm your fish but it will give them the runs... no big deal. Leave them for 48 hours (you can stop after 24 hours if the fish dont react very well to the meds) and after that time do another 90% water change, once again making sure to vacuum the substrate very well. Repeat the treatment 2 weeks later. This should get rid of them. Do not try to pull them out of the fish, and do not think it will go away by itself.
I got all my info from Sharn, as she wrote an article in the aquarium world a little way back. Good luck!