Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

How do I create a web directory in vb.net using ftp

Posted on 2009-05-07
1
Medium Priority
?
796 Views
Last Modified: 2013-11-07
I'm using visual studio 2005 and vb.net and need to create a folder on a remote webiste. I have full credntials for the site.
0
Comment
Question by:FUNDEZ
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 13

Accepted Solution

by:
iHadi earned 2000 total points
ID: 24330709
Hi

try the following:
        Dim destUri As String = "ftp://yourHostNameOrIp.com/DirToCreate"
        Dim username As String
        Dim password As String
 
        Dim ftpReq As FtpWebRequest = CType(WebRequest.Create(destUri), FtpWebRequest)
        ftpReq.Method = WebRequestMethods.Ftp.MakeDirectory
        ftpReq.Credentials = New NetworkCredential(username, password)
 
        ftpReq.Proxy = Nothing
 
        Dim ftpResp As FtpWebResponse = CType(ftpReq.GetResponse(), FtpWebResponse)
        Console.WriteLine("Code:" + ftpResp.StatusCode.ToString())
        Console.WriteLine("Desc:" + ftpResp.StatusDescription.ToString())

Open in new window

0

Featured Post

Veeam Task Manager for Hyper-V

Task Manager for Hyper-V provides critical information that allows you to monitor Hyper-V performance by displaying real-time views of CPU and memory at the individual VM-level, so you can quickly identify which VMs are using host resources.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

It’s quite interesting for me as I worked with Excel using vb.net for some time. Here are some topics which I know want to share with others whom this might help. First of all if you are working with Excel then you need to Download the Following …
A long time ago (May 2011), I have written an article showing you how to create a DLL using Visual Studio 2005 to be hosted in SQL Server 2005. That was valid at that time and it is still valid if you are still using these versions. You can still re…
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …
In this video, Percona Solutions Engineer Barrett Chambers discusses some of the basic syntax differences between MySQL and MongoDB. To learn more check out our webinar on MongoDB administration for MySQL DBA: https://www.percona.com/resources/we…

618 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question