This might be more than what you can chew at this time, but it's a start.
Once you have your input form designed, in your button's click event, whatever you happened to name this button (Ok, Save, Post, etc.) you call this function passing it the parameter you see fit, in this example, you're...