public static HttpPostParameter CreateFile(string name, string fileName, Stream fileStream, string contentType)
 {
     var parameter = new HttpPostParameter(name, string.Empty)
     {
         Type = HttpPostParameterType.File,
         FileName = fileName,
         FileStream = fileStream,
         ContentType = contentType,
     };
     return parameter;
 }
Exemple #2
0
        public static HttpPostParameter CreateFile(string name, string fileName, Stream fileStream, string contentType)
        {
            var parameter = new HttpPostParameter(name, string.Empty)
            {
                Type        = HttpPostParameterType.File,
                FileName    = fileName,
                FileStream  = fileStream,
                ContentType = contentType,
            };

            return(parameter);
        }