Visual Studio 2008 - Not recommended for Download
Download Visual Studio 2010 here.
Download Visual Studio 2012 here.
Download Visual Studio 2013 here.
You need to sign up first to download the application.
After installing the Microsoft Visual Studio. I can now show you how to create a VB.Net project.
- Open MS Visual Studio (I'm using Visual Studio 2010)
- Click New Project or key in Ctrl+Shift+N on your keyboard
- Find Visual Basic on Intalled Templates tab on the left-side of the pop-up window.
- Click Windows Forms Application
- Rename the default filename to My First Program in VB.Net (A new folder will be created on the File directory with the same name as your filename. This will hold all the files that is associated with your project.
- Keep the location same as default.
- Click OK.
- Now a form be seen on the screen. The default name is Form1. You can see its properties by Right-Click on the mouse and click Properties.
- You can rename the form. Find the Name Property and rename it to MyForm1. Find Text Property and enter My First Form.
- Try running this program by pressing F5 or click debug on the menu bar.
- You can see that there are 2 different views. The design environment and debug environment.
- Design environment is where we add controls (label, textbox, button, etc. ) to the form and code of course. Debug is where we test our program.
- To add controls (label, textbox, button etc.) press Ctrl+Alt+X or click View on the menu bar and click ToolBox.
- Under ToolBox, we'll see set of controls. We're going to create a simple form with a label, textbox and button.
- Double click label on the ToolBox. Place it on the left side of the form and Right-click and click Properties and locate Name Property and rename it to lblName, set Text Property to Name:
- Add textbox to your form. Double click or single click and click on the form and click and drag the textbox next to label. Change its Name property to txtboxName.
- Last Add Button to your form. Change the Name property to btnOk. Change Text Property to OK.
- Double Click on the Button. Write the following code where the cursor goes when you click on the button control.
Dim name As String
name = txtboxName.Text
MsgBox("Hello " & name)
That's it! You've just created your First VB.Net Form
Please email me @ lizducos17@gmail.com or leave a comment below.