Greetings and welcome.
-- now that the greetings are done.
you should use code tags for your code --- please read the FAQs prior to posting.
you did not pose a question --- this is not a codemill ---- please read the FAQs prior to posting.
Please focus and give us a question with your understanding and we shall try to point you in the proper direction.
After you have read the FAQs, you may want to answer the following questions for us:
Where are you having difficulty?
Why are you having this difficuly?
How would you like to approch this problem?
And what do you see as going wroing with your approch?
-steve