Could I also suggest that you post ALL the code, for a proper evaluation of what you have done. Don't leave us guessing.