Mega Code Archive

 
Categories / VisualBasic Script / Language Basics
 

To make sure that the user has chosen the OK button, check that the input box hasnt returned a zero-length string

Sub res()     Dim strWhichOffice          strWhichOffice = InputBox("Enter the name of the office:", _         "Expense Assistant 2000", "default", , , _         "c:\Help.chm", 0)     If strWhichOffice = "" Then End End Sub