The FileUpload control displays a text box control and a browse button that allow users to select a file on the client and upload it to the Web server. The user specifies the file to upload by entering the full path to the file on the local computer (for example, C:\MyFiles\TestFile.txt) in the text box of the control. Alternatively, the user can select the file by clicking the Browse button, and then locating it in the Choose File dialog box.
The FileUpload control does not automatically send a file to the server after the user selects the file to upload. You must explicitly provide a control or mechanism to allow the user to submit the form. Typically, the file is saved or the contents handled in an event-handling method for an event that raises a post back to the server. For example, if you provide a button to submit a file, you could place the code to save the file inside the event-handling method for the click event. For more information on the FileUpload control, see FileUpload Web Server Control.