For the record, though, InputBox is a simple function that allows you to ask the user for some basic piece of information, such as her name, the location of a file, or just about anything else your script might need. The function expects one required parameter, the prompt text, and also accepts several optional parameters. I have only used the one required parameter. When this script is executed, the InputBox code will cause a dialogue box to pop up.

Note that the parameter text that we passed, "Please enter your name:", is displayed as a prompt for the dialogue box. The InputBox function returns the value that the user types in, if any. If the user does not type anything in, or clicks the Cancel button, then InputBox will return a zero-length string, which is a strange kind of programming concept that basically means "text with no actual text in it." Our Script stores the result of the InputBox function in the UserName variable.