If you want help with code, you'll have to provide an SSCCE that demonstrates the problem. Note that this does NOT mean you should post all of your code- boil it down to as few lines as possible.