I had the same problem a while ago, and thought that something went wrong with the events handler as it kept on going in to a loop. But the debugger was my best friend.. I ended up debugging the function from the start, and right at the end there was this line of code hiding away that does a call back to the event which caused the function to loop, and loop.. This was also a result of a function that I took over from another developer and this line of code was "Accidentally" put there. I took it out and all worked again.
Good luck