- 1). Click “Start,” “All Programs” and “Visual Basic” to enter the Visual Basic Integrated Development Interface. Click “File” and “New” to create a new project. Select “Windows Form Application.” Enter a name for the project. Choose a location to store the project files by clicking “Browse.”
- 2). Click “Form1” on the “Solution Explorer.” Click “Toolbox” and then “Textbox.” Drop the “Textbox” on the form by clicking the blank area. Similarly click “Button” on the toolbox and drop two buttons. Finally create a “Timer.”
- 3). Go to “Properties.” Change the “Text” of the new textbox to text1, where you can input your target’s IP address. Set the “Text” of buttons to button1 and button2 respectively. Rename “Timer” as timer1.
- 4). Double-click the button1 and enter the following code between Sub and End Sub:
timer1.Enabled=True
Double-click button2 and enter the following:
timer1.Enabled=False
Double-click Timer1 and enter code:
Shell (“ping”+ (text1.Text) +”-1”+”65000”)
previous post
next post