Forums before death by AOL, social media and spammers... "We can't have nice things"
|    comp.lang.visual.basic    |    MS Visual Basic discussions, NOT dot-net    |    10,840 messages    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
|    Message 10,602 of 10,840    |
|    Mitch to All    |
|    vb.net webclient upload file and IIS con    |
|    14 Jul 08 23:09:23    |
   
   From: mhmooney@no.bother.to.spam   
      
   Not sure where to post this but simply I want to upload a file using the   
   WebClient, ie:   
      
   Try   
    Dim wc As New WebClient   
    wc.Credentials = New System.Net.NetworkCredential("someuser",   
   "somepass")   
    wc.UploadFile("http://localhost/public/", "PUT", "c:\test.txt")   
   Catch ex As Exception   
    Console.WriteLine(ex.Message)   
    Console.ReadKey()   
   End Try   
      
   It always returns : The remote server returned an error: (403) Forbidden.   
      
   I have permissions set on public for read/write, I have web shared the   
   folder. Im guessing its how I have IIS setup. Using XP Pro sp3 and IIS.   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   
|
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
(c) 1994, bbs@darkrealms.ca