You want to transfer an image or a file to or from a Web service.
Submit or return the data as a byte array.
Web services support only a carefully limited set of data types, an approach that’s designed to ensure optimum cross-platform compatibility. However, you can transmit virtually anything if you convert it to binary first.
The following Web service accepts a byte array and saves it directly to disk. For this code to work, the ASP.NET process must have privileges to write to the appropriate directory. You should also import the System.IO namespace.
<WebService()> _ Public Class UploadData Inherits System.Web.Services.WebService <WebMethod()> _ Public Sub UploadFile(ByVal originalName ...