HTML by definition will not allow you to do that.
HTML = Hyper Text Markup Language, and that's all it is. It's a bunch of XML-style code that will tell your browser HOW to display something. It won't make anything interactive, per se.
You'll want to venture into Java, PHP, ASP .. some other kind of interactive language for that.