First of all, posted in the wrong place dude! Should not be in the Code Snippet Section! Secondly, don't use CAPLOCKS when writting messages!
Saying that;
What you are asking is a standard (basic) 2 Tier Application. Show us what you have so far, and we can help you out where you are having difficulty, but we can not give you the answer to your question. But, if you do a google search you can find numerous code snippets on how to "basically" do what you are asking.