MSN Posted February 2, 2003 Posted February 2, 2003 About the InputBox Function, I've been having trouble coding the CancelButton (under VB.net). Any ideas? MSN Quote
*Experts* Bucky Posted February 3, 2003 *Experts* Posted February 3, 2003 I don't understand what you mean. The CancelButton property of a form closes that form and returns a DialogResult of Cancel if that form is shown by using ShowDialog. If you want code to be run when this button is clicked, just add code in its Click event handler. The InputBox function (which is from VB6 and shouldn't be used) only returns a String, so I'm not sure where the CancelButton comes into play here. You can check if the return string is empty to see if the user pressed Cancel, if that's what you mean. Quote "Being grown up isn't half as fun as growing up These are the best days of our lives" -The Ataris, In This Diary
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.