FORM
MODULE
PHP Code:
Public Class Form1
Dim Komut As New AutoItX3Lib.AutoItX3
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Timer1.Interval = Val(TextBox2.Text) * 200
Label1.ForeColor = Color.Green
Label1.Text = "ACIK"
Timer1.Enabled = True
End Sub
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
Timer1.Enabled = False
Label1.ForeColor = Color.Red
Label1.Text = "KAPALI"
End Sub
Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click
Timer2.Interval = Val(TextBox3.Text) * 200
Label2.ForeColor = Color.Green
Label2.Text = "ACIK"
Timer2.Enabled = True
End Sub
Private Sub Button6_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button6.Click
Timer3.Enabled = True
Timer3.Interval = Val(TextBox5.Text) * 200
Label3.ForeColor = Color.Green
Label3.Text = "ACIK"
End Sub
Private Sub Button8_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button8.Click
Timer4.Enabled = True
Timer4.Interval = Val(TextBox7.Text) * 200
Label4.ForeColor = Color.Green
Label4.Text = "ACIK"
End Sub
Private Sub Button12_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button12.Click
Timer6.Enabled = True
Timer6.Interval = Val(TextBox11.Text) * 200
Label6.ForeColor = Color.Green
Label6.Text = "ACIK"
End Sub
Private Sub Button14_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button14.Click
Timer7.Enabled = True
Timer7.Interval = Val(TextBox13.Text) * 200
Label7.ForeColor = Color.Green
Label7.Text = "ACIK"
End Sub
Private Sub Button16_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button16.Click
Timer8.Enabled = True
Timer8.Interval = Val(TextBox15.Text) * 200
Label8.ForeColor = Color.Green
Label8.Text = "ACIK"
End Sub
Private Sub Button18_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button18.Click
Timer9.Enabled = True
Timer9.Interval = Val(TextBox17.Text) * 200
Label9.ForeColor = Color.Green
Label9.Text = "ACIK"
End Sub
Private Sub Button20_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button20.Click
Timer10.Enabled = True
Timer10.Interval = Val(TextBox19.Text) * 200
Label32.ForeColor = Color.Green
Label32.Text = "ACIK"
End Sub
Private Sub Button10_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button10.Click
Timer5.Enabled = True
Timer5.Interval = Val(TextBox9.Text) * 200
Label5.ForeColor = Color.Green
Label5.Text = "ACIK"
End Sub
Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
Timer2.Enabled = False
Label2.ForeColor = Color.Red
Label2.Text = "KAPALI"
End Sub
Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click
Timer3.Enabled = False
Label3.ForeColor = Color.Red
Label3.Text = "KAPALI"
End Sub
Private Sub Button7_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button7.Click
Timer4.Enabled = False
Label4.ForeColor = Color.Red
Label4.Text = "KAPALI"
End Sub
Private Sub Button9_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button9.Click
Timer5.Enabled = False
Label5.ForeColor = Color.Red
Label5.Text = "KAPALI"
End Sub
Private Sub Button11_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button11.Click
Timer6.Enabled = False
Label6.ForeColor = Color.Red
Label6.Text = "KAPALI"
End Sub
Private Sub Button13_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button13.Click
Timer7.Enabled = False
Label7.ForeColor = Color.Red
Label7.Text = "KAPALI"
End Sub
Private Sub Button15_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button15.Click
Timer8.Enabled = False
Label8.ForeColor = Color.Red
Label8.Text = "KAPALI"
End Sub
Private Sub Button17_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button17.Click
Timer9.Enabled = False
Label9.ForeColor = Color.Red
Label9.Text = "KAPALI"
End Sub
Private Sub Button19_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button19.Click
Timer10.Enabled = False
Label32.ForeColor = Color.Red
Label32.Text = "KAPALI"
End Sub
Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
SendKeys.Send(TextBox1.Text)
End Sub
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim fileExists As Boolean
fileExists = My.Computer.FileSystem.FileExists("AutoItX3.dll")
If fileExists = False Then
MsgBox("AutoItX3.dll Bulunamadı ! ,Bazı programlar doğru çalışmayablir !!!")
End If
If fileExists = True Then
Call Register(CurDir() & "\AutoItX3.dll")
End If
Process.Start("http://www.facebook.com/omansakosk")
Timer1.Start()
Timer1.Enabled = False
Timer2.Start()
Timer2.Enabled = False
Timer3.Start()
Timer3.Enabled = False
Timer4.Start()
Timer4.Enabled = False
Timer5.Start()
Timer5.Enabled = False
Timer6.Start()
Timer6.Enabled = False
Timer7.Start()
Timer7.Enabled = False
Timer8.Start()
Timer8.Enabled = False
Timer9.Start()
Timer9.Enabled = False
Timer10.Start()
Timer10.Enabled = False
End Sub
Private Sub Timer2_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer2.Tick
SendKeys.Send(TextBox4.Text)
End Sub
Private Sub Timer3_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer3.Tick
SendKeys.Send(TextBox6.Text)
End Sub
Private Sub Timer4_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer4.Tick
SendKeys.Send(TextBox8.Text)
End Sub
Private Sub Timer5_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer5.Tick
SendKeys.Send(TextBox10.Text)
End Sub
Private Sub Timer6_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer6.Tick
SendKeys.Send(TextBox12.Text)
End Sub
Private Sub Timer7_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer7.Tick
SendKeys.Send(TextBox14.Text)
End Sub
Private Sub Timer8_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer8.Tick
SendKeys.Send(TextBox16.Text)
End Sub
Private Sub Timer9_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer9.Tick
SendKeys.Send(TextBox18.Text)
End Sub
Private Sub Timer10_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer10.Tick
SendKeys.Send(TextBox20.Text)
End Sub
Private Sub LinkLabel1_LinkClicked(ByVal sender As System.Object, ByVal e As System.Windows.Forms.LinkLabelLinkClickedEventArgs) Handles LinkLabel1.LinkClicked
Process.Start("http://libermetin2.host.org")
End Sub
Private Sub LinkLabel2_LinkClicked(ByVal sender As System.Object, ByVal e As System.Windows.Forms.LinkLabelLinkClickedEventArgs) Handles LinkLabel2.LinkClicked
Process.Start("http://www.facebook.com/omansakosk")
End Sub
End Class
MODULE
PHP Code:
Module Module1
Private Declare Function LoadLibraryRegister Lib "kernel32" Alias "LoadLibraryA" (ByVal lpLibFileName As String) As Long
Private Declare Function GetProcAddressRegister Lib "kernel32" Alias "GetProcAddress" (ByVal hModule As Long, ByVal lpProcName As String) As Long
Private Declare Function CreateThreadForRegister Lib "kernel32" Alias "CreateThread" (ByVal lpThreadAttributes As Long, ByVal dwStackSize As Long, ByVal lpStartAddress As Long, ByVal lpParameter As Long, ByVal dwCreationFlags As Long, ByVal lpThreadID As Long) As Long
Private Declare Function WaitForSingleObject Lib "kernel32" (ByVal hHandle As Long, ByVal dwMilliseconds As Long) As Long
Private Declare Function GetExitCodeThread Lib "kernel32" (ByVal hThread As Long, ByVal lpExitCode As Long) As Long
Private Declare Sub ExitThread Lib "kernel32" (ByVal dwExitCode As Long)
Private Declare Function CloseHandle Lib "kernel32" (ByVal hObject As Long) As Long
Private Declare Function FreeLibraryRegister Lib "kernel32" Alias "FreeLibrary" (ByVal hLibModule As Long) As Long
Dim stFileCouldNotBeLoadedIntoMemorySpace As Integer
Dim stNotAValidActiveXComponent As Integer
Dim stActiveXComponentRegistrationFailed As Integer
Dim stActiveXComponentRegistrationSuccessful As Integer
Dim stActiveXComponentUnRegisterSuccessful As Integer
Dim stActiveXComponentUnRegistrationFailed As Integer
Dim stNoFileProvided As Integer
Private Const NOERRORS As Long = 0
Private Const STATUS_WAIT_0 = &H0
Private Const WAIT_OBJECT_0 = ((STATUS_WAIT_0) + 0)
Private Enum stRegisterStatus
stFileCouldNotBeLoadedIntoMemorySpace = 1
stNotAValidActiveXComponent = 2
stActiveXComponentRegistrationFailed = 3
stActiveXComponentRegistrationSuccessful = 4
stActiveXComponentUnRegisterSuccessful = 5
stActiveXComponentUnRegistrationFailed = 6
stNoFileProvided = 7
End Enum
Public Function Register(ByVal p_sFileName As String) As Object
Dim lLib As Long
Dim lProcAddress As Long
Dim lThreadID As Long
Dim lSuccess As Long
Dim lExitCode As Long
Dim lThreadHandle As Long
Dim lRet As Long
On Error GoTo ErrorHandler
If lRet = NOERRORS Then
If p_sFileName = "" Then
lRet = stNoFileProvided
End If
End If
If lRet = NOERRORS Then
lLib = LoadLibraryRegister(p_sFileName)
If lLib = 0 Then
lRet = stFileCouldNotBeLoadedIntoMemorySpace
End If
End If
If lRet = NOERRORS Then
lProcAddress = GetProcAddressRegister(lLib, "DllRegisterServer")
If lProcAddress = 0 Then
lRet = stNotAValidActiveXComponent
Else
lThreadHandle = CreateThreadForRegister(0, 0, lProcAddress, 0, 0, lThreadID)
If lThreadHandle <> 0 Then
lSuccess = (WaitForSingleObject(lThreadHandle, 10000) = WAIT_OBJECT_0)
If lSuccess = 0 Then
Call GetExitCodeThread(lThreadHandle, lExitCode)
Call ExitThread(lExitCode)
lRet = stActiveXComponentRegistrationFailed
Else
lRet = stActiveXComponentRegistrationSuccessful
End If
End If
End If
End If
ExitRoutine:
Register = lRet
If lThreadHandle <> 0 Then
Call CloseHandle(lThreadHandle)
End If
If lLib <> 0 Then
Call FreeLibraryRegister(lLib)
End If
Exit Function
ErrorHandler:
lRet = Err.Number
GoTo ExitRoutine
End Function
End Module






