Hello mschipper,

My recommendation would be to go to MCA's site and try out his KIXSTRIP tool for the version of the KiXtart you're using.

MCA's website (good scripts and tools)

I often feel sorry for new comers and will try to go the extra mile where I can, but as Les says... this is TOO much code to manually sift through for errors when it is not on your own system.