As a full member now, you should know that we expect your code to be posted in [code] tags (See
How to Ask a Question).
This makes it easier for our Experts to read and understand it. Failing to do so creates extra work for the moderators, thus wasting resources, otherwise available to answer the members' questions.
Please use the tags in future.
MODERATOR.
I'm moving this to the .NET forum as this is obviously a .NET problem.