DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

+ Reply to Thread
Results 1 to 2 of 2
  1. #1
    news://news.devx.com Guest

    Problem with WebClient class

    Hello,
    I have problem with upload a file to IIS server. If I use UploadFile (from
    System.Net.WebClient class) method in way UploadFile(uriString, "POST",
    fileName) but I receive error message: Error 405 - method not allowed
    If I use "PUT" instead of "POST" then this file is uploaded to server but
    this file has additional content.
    For example:
    If I have text file with only 2 lines:
    Pawel
    End

    then after uploading this file to server its content is:
    -----------------------8c4b770cd594720
    Content-Disposition: form-data; name="file"; filename="pawel.txt"
    Content-Type: application/octet-stream

    Pawel
    End
    -----------------------8c4b770cd594720

    Can you help ? Thanks a lot.

    Paweł Przybyła




  2. #2
    Kuku Guest

    Re: Problem with WebClient class


    Hello

    >What's the point to use UploadFile.....?
    >Do you have wife..?
    >Let her do it !!!!



Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


Top DevX Stories

Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL


Sponsored Links