405 lines
15 KiB
VB.net
405 lines
15 KiB
VB.net
Imports System.ComponentModel
|
|
Imports System.IO
|
|
Imports System.Net
|
|
|
|
Public Class Form42
|
|
Private Sub BackgroundWorker1_DoWork(sender As Object, e As System.ComponentModel.DoWorkEventArgs)
|
|
|
|
End Sub
|
|
|
|
Private Sub Form42_Load(sender As Object, e As EventArgs) Handles MyBase.Load
|
|
Dim maj1 As New WebClient
|
|
Dim vri1 As String = maj1.DownloadString("http://logiciels2.extreme-downloaders.fr/extreme downloaders/server%20temps.txt")
|
|
If vri1 = 1 Then
|
|
Label4.Text = "acctivez"
|
|
Label12.Text = "acctivez"
|
|
Else
|
|
Label4.Text = "désacctivez"
|
|
Label12.Text = "désacctivez"
|
|
End If
|
|
Dim maj2 As New WebClient
|
|
Dim vri2 As String = maj2.DownloadString(ipsite & "extrème downloaders/jour.txt")
|
|
Dim maj3 As New WebClient
|
|
Dim vri3 As String = maj2.DownloadString(ipsite & "extrème downloaders/moins.txt")
|
|
Label6.Text = vri2 & "/" & vri3
|
|
Label15.Text = vri2 & "/" & vri3
|
|
Dim maj4 As New WebClient
|
|
Dim vri4 As String = maj4.DownloadString("http://logiciels2.extreme-downloaders.fr/extr%c3%a8me%20downloaders/version.txt")
|
|
Label8.Text = vri4
|
|
|
|
Try
|
|
ListBox1.Items.Clear()
|
|
Dim fwr As FtpWebRequest
|
|
fwr = FtpWebRequest.Create(ipserver & "/utilisateur/")
|
|
fwr.Credentials = New NetworkCredential("extremedownloaders", passftp)
|
|
fwr.Method = WebRequestMethods.Ftp.ListDirectory
|
|
Dim sr As New StreamReader(fwr.GetResponse().GetResponseStream())
|
|
|
|
Dim str As String = sr.ReadLine()
|
|
While Not str Is Nothing
|
|
|
|
ListBox1.Items.Add(str)
|
|
|
|
str = sr.ReadLine()
|
|
|
|
End While
|
|
|
|
|
|
sr.Close()
|
|
|
|
Label2.Text = ListBox1.Items.Count
|
|
|
|
Timer3.Start()
|
|
|
|
|
|
Catch ex As Exception
|
|
Timer1.Start()
|
|
End Try
|
|
End Sub
|
|
|
|
Private Sub Timer1_Tick(sender As Object, e As EventArgs) Handles Timer1.Tick
|
|
Timer1.Stop()
|
|
Try
|
|
ListBox1.Items.Clear()
|
|
Dim fwr As FtpWebRequest
|
|
fwr = FtpWebRequest.Create(ipserver & "/utilisateur/")
|
|
fwr.Credentials = New NetworkCredential("extremedownloaders", passftp)
|
|
fwr.Method = WebRequestMethods.Ftp.ListDirectory
|
|
Dim sr As New StreamReader(fwr.GetResponse().GetResponseStream())
|
|
|
|
Dim str As String = sr.ReadLine()
|
|
While Not str Is Nothing
|
|
|
|
ListBox1.Items.Add(str)
|
|
|
|
str = sr.ReadLine()
|
|
|
|
End While
|
|
|
|
|
|
sr.Close()
|
|
|
|
Label2.Text = ListBox1.Items.Count
|
|
|
|
Timer2.Start()
|
|
|
|
|
|
Catch ex As Exception
|
|
Timer1.Start()
|
|
End Try
|
|
End Sub
|
|
|
|
Private Sub Timer2_Tick(sender As Object, e As EventArgs) Handles Timer2.Tick
|
|
Timer2.Stop()
|
|
Dim maj1 As New WebClient
|
|
Dim vri1 As String = maj1.DownloadString("http://logiciels2.extreme-downloaders.fr/extreme downloaders/server%20temps.txt")
|
|
If vri1 = 1 Then
|
|
Label4.Text = "acctivez"
|
|
Label12.Text = "acctivez"
|
|
Else
|
|
Label4.Text = "désacctivez"
|
|
Label12.Text = "désacctivez"
|
|
End If
|
|
Dim maj2 As New WebClient
|
|
Dim vri2 As String = maj2.DownloadString(ipsite & "extrème downloaders/jour.txt")
|
|
Dim maj3 As New WebClient
|
|
Dim vri3 As String = maj2.DownloadString(ipsite & "extrème downloaders/moins.txt")
|
|
Label6.Text = vri2 & "/" & vri3
|
|
Label15.Text = vri2 & "/" & vri3
|
|
Dim maj4 As New WebClient
|
|
Dim vri4 As String = maj4.DownloadString("http://logiciels2.extreme-downloaders.fr/extr%c3%a8me%20downloaders/version.txt")
|
|
Label8.Text = vri4
|
|
|
|
Try
|
|
ListBox1.Items.Clear()
|
|
Dim fwr As FtpWebRequest
|
|
fwr = FtpWebRequest.Create(ipserver & "/utilisateur/")
|
|
fwr.Credentials = New NetworkCredential("extremedownloaders", passftp)
|
|
fwr.Method = WebRequestMethods.Ftp.ListDirectory
|
|
Dim sr As New StreamReader(fwr.GetResponse().GetResponseStream())
|
|
|
|
Dim str As String = sr.ReadLine()
|
|
While Not str Is Nothing
|
|
|
|
ListBox1.Items.Add(str)
|
|
|
|
str = sr.ReadLine()
|
|
|
|
End While
|
|
|
|
|
|
sr.Close()
|
|
|
|
Label2.Text = ListBox1.Items.Count
|
|
|
|
Timer2.Start()
|
|
|
|
|
|
Catch ex As Exception
|
|
Timer1.Start()
|
|
End Try
|
|
End Sub
|
|
|
|
Private Sub Panel5_Click(sender As Object, e As EventArgs) Handles Panel5.Click
|
|
Form40.ShowDialog()
|
|
End Sub
|
|
|
|
Private Sub Label13_Click(sender As Object, e As EventArgs) Handles Label13.Click
|
|
Form40.ShowDialog()
|
|
End Sub
|
|
|
|
Private Sub PictureBox20_Click(sender As Object, e As EventArgs) Handles PictureBox20.Click
|
|
Form40.ShowDialog()
|
|
End Sub
|
|
Private Sub Panel3_Click(sender As Object, e As EventArgs) Handles Panel3.Click
|
|
Try
|
|
Form7.ShowDialog()
|
|
|
|
Catch ex As Exception
|
|
Form7.Close()
|
|
Form7.ShowDialog()
|
|
End Try
|
|
End Sub
|
|
|
|
Private Sub Label9_Click(sender As Object, e As EventArgs) Handles Label9.Click
|
|
Try
|
|
Form7.ShowDialog()
|
|
|
|
Catch ex As Exception
|
|
Form7.Close()
|
|
Form7.ShowDialog()
|
|
End Try
|
|
End Sub
|
|
|
|
Private Sub PictureBox3_Click(sender As Object, e As EventArgs) Handles PictureBox3.Click
|
|
Try
|
|
Form7.ShowDialog()
|
|
|
|
Catch ex As Exception
|
|
Form7.Close()
|
|
Form7.ShowDialog()
|
|
End Try
|
|
End Sub
|
|
|
|
Private Sub Panel1_Click(sender As Object, e As EventArgs) Handles Panel1.Click
|
|
Form29.ShowDialog()
|
|
End Sub
|
|
|
|
Private Sub Panel1_Paint(sender As Object, e As PaintEventArgs)
|
|
|
|
End Sub
|
|
|
|
Private Sub Panel3_Paint(sender As Object, e As PaintEventArgs)
|
|
|
|
End Sub
|
|
|
|
Private Sub Panel5_Paint(sender As Object, e As PaintEventArgs)
|
|
|
|
End Sub
|
|
|
|
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
|
|
Form6.Timer1.Stop()
|
|
Dim sw1 As New StreamWriter(dostemps & "server temps.txt")
|
|
sw1.WriteLine(1)
|
|
sw1.Close()
|
|
Dim ipserveur2 As String = "ftp://extre1948521:Jjamsms77176!@185.135.132.49:21/"
|
|
My.Computer.Network.UploadFile(dostemps & "server temps.txt", ipserveur2 & "extreme downloaders/server temps.txt")
|
|
File.Delete(dostemps & "server temps.txt")
|
|
Dim maj1 As New WebClient
|
|
Dim vri1 As String = maj1.DownloadString("http://logiciels2.extreme-downloaders.fr/extreme downloaders/server temps.txt")
|
|
If vri1 = 1 Then
|
|
Label4.Text = "acctivez"
|
|
Label12.Text = "acctivez"
|
|
Else
|
|
Label4.Text = "désacctivez"
|
|
Label12.Text = "désacctivez"
|
|
End If
|
|
End Sub
|
|
|
|
Private Sub Button2_Click(sender As Object, e As EventArgs) Handles Button2.Click
|
|
Dim sw1 As New StreamWriter(dostemps & "server temps.txt")
|
|
sw1.WriteLine(0)
|
|
sw1.Close()
|
|
Dim ipserveur2 As String = "ftp://extre1948521:Jjamsms77176!@185.135.132.49:21/"
|
|
My.Computer.Network.UploadFile(dostemps & "server temps.txt", ipserveur2 & "extreme downloaders/server temps.txt")
|
|
File.Delete(dostemps & "server temps.txt")
|
|
Dim maj1 As New WebClient
|
|
Dim vri1 As String = maj1.DownloadString("http://logiciels2.extreme-downloaders.fr/extreme downloaders/server temps.txt")
|
|
Form6.Timer1.Start()
|
|
If vri1 = 1 Then
|
|
Label4.Text = "acctivez"
|
|
Label12.Text = "acctivez"
|
|
Else
|
|
Label4.Text = "désacctivez"
|
|
Label12.Text = "désacctivez"
|
|
End If
|
|
End Sub
|
|
|
|
Private Sub Label17_Click(sender As Object, e As EventArgs) Handles Label17.Click
|
|
|
|
End Sub
|
|
|
|
Private Sub Button3_Click(sender As Object, e As EventArgs) Handles Button3.Click
|
|
If Button3.Text = "modifier" Then
|
|
TextBox1.Show()
|
|
TextBox2.Show()
|
|
Label16.Show()
|
|
Label17.Show()
|
|
Button3.Text = "envoyer"
|
|
ElseIf Button3.Text = "envoyer" Then
|
|
If TextBox1.Text = "" Then
|
|
MsgBox("merci d'enterer un jours", MsgBoxStyle.Exclamation)
|
|
Else
|
|
If TextBox2.Text = "" Then
|
|
MsgBox("merci d'enterer un mois", MsgBoxStyle.Exclamation)
|
|
Else
|
|
Dim sw1 As New StreamWriter(dostemps & "jour.txt")
|
|
sw1.WriteLine(TextBox1.Text)
|
|
sw1.Close()
|
|
Dim sw2 As New StreamWriter(dostemps & "moins.txt")
|
|
sw2.WriteLine(TextBox2.Text)
|
|
sw2.Close()
|
|
My.Computer.Network.UploadFile(dostemps & "jour.txt", ipserver & "/jour.txt")
|
|
My.Computer.Network.UploadFile(dostemps & "moins.txt", ipserver & "/moins.txt")
|
|
File.Delete(dostemps & "jour.txt")
|
|
File.Delete(dostemps & "moins.txt")
|
|
Dim maj2 As New WebClient
|
|
Dim vri2 As String = maj2.DownloadString(ipsite & "extrème downloaders/jour.txt")
|
|
Dim maj3 As New WebClient
|
|
Dim vri3 As String = maj2.DownloadString(ipsite & "extrème downloaders/moins.txt")
|
|
Label6.Text = vri2 & "/" & vri3
|
|
Label15.Text = vri2 & "/" & vri3
|
|
TextBox1.Hide()
|
|
TextBox2.Hide()
|
|
Label16.Hide()
|
|
Label17.Hide()
|
|
TextBox1.Clear()
|
|
TextBox2.Clear()
|
|
Button3.Text = "modifier"
|
|
End If
|
|
End If
|
|
End If
|
|
End Sub
|
|
|
|
Private Sub Form42_Closing(sender As Object, e As CancelEventArgs) Handles Me.Closing
|
|
TextBox1.Hide()
|
|
TextBox2.Hide()
|
|
Label16.Hide()
|
|
Label17.Hide()
|
|
TextBox1.Clear()
|
|
TextBox2.Clear()
|
|
ListBox1.Items.Clear()
|
|
Button3.Text = "modifier"
|
|
Dim sw1 As New StreamWriter(dostemps & "server temps.txt")
|
|
sw1.WriteLine(0)
|
|
sw1.Close()
|
|
Dim ipserveur2 As String = "ftp://extre1948521:Jjamsms77176!@185.135.132.49:21/"
|
|
My.Computer.Network.UploadFile(dostemps & "server temps.txt", ipserveur2 & "extreme downloaders/server temps.txt")
|
|
File.Delete(dostemps & "server temps.txt")
|
|
Form6.Timer1.Start()
|
|
End Sub
|
|
|
|
Private Sub Timer3_Tick(sender As Object, e As EventArgs) Handles Timer3.Tick
|
|
Timer3.Stop()
|
|
Try
|
|
ComboBox1.Items.Clear()
|
|
Dim fwr As FtpWebRequest
|
|
fwr = FtpWebRequest.Create(ipserver & "/utilisateur/")
|
|
fwr.Credentials = New NetworkCredential("extremedownloaders", passftp)
|
|
fwr.Method = WebRequestMethods.Ftp.ListDirectory
|
|
Dim sr As New StreamReader(fwr.GetResponse().GetResponseStream())
|
|
|
|
Dim str As String = sr.ReadLine()
|
|
While Not str Is Nothing
|
|
|
|
ComboBox1.Items.Add(str)
|
|
|
|
str = sr.ReadLine()
|
|
|
|
End While
|
|
|
|
|
|
sr.Close()
|
|
|
|
ComboBox1.SelectedIndex = 0
|
|
|
|
|
|
Catch ex As Exception
|
|
Timer3.Start()
|
|
End Try
|
|
End Sub
|
|
|
|
Private Sub ComboBox1_SelectedIndexChanged(sender As Object, e As EventArgs) Handles ComboBox1.SelectedIndexChanged
|
|
|
|
End Sub
|
|
|
|
Private Sub ComboBox1_SelectedValueChanged(sender As Object, e As EventArgs) Handles ComboBox1.SelectedValueChanged
|
|
Dim maj1 As New WebClient
|
|
Dim vri1 As String = maj1.DownloadString(ipsite & "/extrème downloaders/utilisateur/" & ComboBox1.SelectedItem & "/XP.txt")
|
|
Label18.Text = "compte de: " & ComboBox1.SelectedItem
|
|
Label19.Text = "Nombre de XP: " & vri1
|
|
Dim maj2 As New WebClient
|
|
Dim vri2 As String = maj2.DownloadString(ipsite & "/extrème downloaders/utilisateur/" & ComboBox1.SelectedItem & "/money.txt")
|
|
Label20.Text = "money: " & vri2
|
|
Dim maj3 As New WebClient
|
|
Dim vri3 As String = maj3.DownloadString(ipsite & "/extrème downloaders/utilisateur/" & ComboBox1.SelectedItem & "/level.txt")
|
|
Label21.Text = "Nombre de niveaux: " & vri3
|
|
Dim maj4 As New WebClient
|
|
Dim vri4 As String = maj4.DownloadString(ipsite & "/extrème downloaders/utilisateur/" & ComboBox1.SelectedItem & "/up.txt")
|
|
Label22.Text = "Nombre de fichier en ligne: " & vri4
|
|
End Sub
|
|
|
|
Private Sub Button5_Click(sender As Object, e As EventArgs) Handles Button5.Click
|
|
Form43.Text = "modifier: XP"
|
|
Dim maj1 As New WebClient
|
|
Dim vri1 As String = maj1.DownloadString(ipsite & "/extrème downloaders/utilisateur/" & ComboBox1.SelectedItem & "/XP.txt")
|
|
Form43.Label1.Text = "Nombre de XP: " & vri1
|
|
Form43.ShowDialog()
|
|
End Sub
|
|
|
|
Private Sub Button4_Click(sender As Object, e As EventArgs) Handles Button4.Click
|
|
Form43.Text = "modifier: money"
|
|
Dim maj1 As New WebClient
|
|
Dim vri1 As String = maj1.DownloadString(ipsite & "/extrème downloaders/utilisateur/" & ComboBox1.SelectedItem & "/money.txt")
|
|
Form43.Label1.Text = "money: " & vri1
|
|
Form43.ShowDialog()
|
|
End Sub
|
|
|
|
Private Sub Button6_Click(sender As Object, e As EventArgs) Handles Button6.Click
|
|
Form43.Text = "modifier: Niveaux"
|
|
Dim maj1 As New WebClient
|
|
Dim vri1 As String = maj1.DownloadString(ipsite & "/extrème downloaders/utilisateur/" & ComboBox1.SelectedItem & "/level.txt")
|
|
Form43.Label1.Text = "Niveaux: " & vri1
|
|
Form43.ShowDialog()
|
|
End Sub
|
|
|
|
Private Sub Button7_Click(sender As Object, e As EventArgs) Handles Button7.Click
|
|
Form43.Text = "modifier: Nombre de fichier en ligne"
|
|
Dim maj1 As New WebClient
|
|
Dim vri1 As String = maj1.DownloadString(ipsite & "/extrème downloaders/utilisateur/" & ComboBox1.SelectedItem & "/up.txt")
|
|
Form43.Label1.Text = "fichier en ligne: " & vri1
|
|
Form43.ShowDialog()
|
|
End Sub
|
|
|
|
Private Sub TextBox1_KeyPress(sender As Object, e As KeyPressEventArgs) Handles TextBox1.KeyPress
|
|
Dim desNumero() As Char = {"0", "1", "2", "3", "4", "5", "6", "7", "8", "9"}
|
|
If Not desNumero.Contains(e.KeyChar) And Not Asc(e.KeyChar) = 8 Then
|
|
e.Handled = True
|
|
End If
|
|
End Sub
|
|
|
|
Private Sub Label10_Click(sender As Object, e As EventArgs) Handles Label10.Click
|
|
Form29.ShowDialog()
|
|
End Sub
|
|
|
|
Private Sub PictureBox1_Click(sender As Object, e As EventArgs) Handles PictureBox1.Click
|
|
Form29.ShowDialog()
|
|
End Sub
|
|
|
|
Private Sub TextBox2_KeyPress(sender As Object, e As KeyPressEventArgs) Handles TextBox2.KeyPress
|
|
Dim desNumero() As Char = {"0", "1", "2", "3", "4", "5", "6", "7", "8", "9"}
|
|
If Not desNumero.Contains(e.KeyChar) And Not Asc(e.KeyChar) = 8 Then
|
|
e.Handled = True
|
|
End If
|
|
End Sub
|
|
End Class |