FTP Connection, Error 530
I was trying to set up a Login system earlier today, and because my webhost request a password to access files, Im stuck.
Here is my code:
I Censored my Details, yes. they were there correctly.
Here is my code:
Code:
Imports System.Net
Imports System.Net.WebClient
Public Class Form1
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
End Sub
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim User As String
Dim Pass As String
Dim request As Net.FtpWebRequest = Net.FtpWebRequest.Create(URL)
request.Credentials = New Net.NetworkCredential(" USERNAME", " PASSWORD")
//Added This, But URL Is not declared. Tried declaring and got new errors.
User = TextBox1.Text
Pass = TextBox2.Text
Dim wc = New WebClient
Dim string01
Dim string02
string01 = wc.DownloadString("ftp:// HIDDEN")
string02 = wc.DownloadString("ftp:// HIDDEN")
If string01.contains(User) Then
If string02.contains(Pass) Then
Form2.Show()
MsgBox("Log in Successful.")
End If
End If
End Sub
End Class
I Censored my Details, yes. they were there correctly.