Here's an extremely detailed sample book chapter that will help explain what you're asking:
http://www.vb2themax.com/HtmlDoc.asp...ID=7100&Page=1