The Web Front End

The next step is to remove the requirement for the sales manager to download and copy the Excel files. The easiest approach that is guaranteed to be supported for all sales notebooks is to create a basic ASP.NET upload page.

ASP.NET allows uploads through the HtmlInputFile control. To allow a user-initiated upload, you need to take three steps:

  1. Set the encoding type of the form to "multipart/form-data". You can do this by setting a property of the HtmlForm control class, or you can just find the tag in your ASPX file and modify as shown here. If you don’t make this change, your uploading code won’t work.

    <form id="Form1" enctype="multipart/form-data" runat="server">   <!— Server controls go here, including the HtmlInputFile control. —> ...

Get Microsoft® .NET Distributed Applications: Integrating XML Web Services and .NET Remoting now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.