VB.NET Programming *Introduction*

advertisement
CSCI N331 VB .NET Programming
1a – Getting Started
Lingma Acheson
Department of Computer and Information Science, IUPUI
Outline
•
•
•
•
•
•
Create a new project
Save a project
Zip up the project folder
Submit a project
Transfer a project
Unzip a project
2
Create A VB.NET Project
• On Windows Vista, Start -> All Programs
-> Microsoft Visual Studio 2008
-> Microsoft Visual Studio 2008
• Set Visual Basic as the default language
• Create Project Or File -> New Project
• Project types: Windows
• Templates: Windows Forms Application
• Enter a project name: Default is
WindowsApplication1, change it to something
meaningful, e.g. Project1, Greetings, etc. No
space in the name.
3
Save A VB.NET Project
• Click on “Save” or “Save All” icon.
• If “Save Project” window pops up, choose
a location you want to save to.
– It is a good idea to create a directory for all the
projects you will create for this class.
– If you didn’t change the project location, the
default location is “My Documents”.
4
Save A VB.NET Project
• Leave the “Solution Name” the same as
the project name.
• Check the box “create directory for
solution”.
• Click on “Save” or “Save All” icon from
time to time when you make changes to
the project.
5
Open A VB.NET Project
• Close the Visual Studio after saving your
project.
• Go to your projects folder and find folder
specifically created for this project.
• Click on the solution file (the Form icon
with a visual studio sign) inside this folder.
• There will be another folder with the
project name by the solution file.
• Click on Form1.vb in the Solution Explorer
panel on the right hand side.
6
Submit A VB.NET Project
• Project files
– A VB.NET project consists of many files.
– They work together to form a project.
– Missing files or changing a file location will
lead to the project not working properly.
• Need to submit all the files
• Zip up your files – pack everything into
one single file
– Use a software tool, e.g. WinRAR, WinZip or 7zip.
– 7-zip is available from iuware.iu.edu
7
Submit A VB.NET Project
• Using 7-zip
– Right click on the project folder ->7-Zip.
– Add to “projectName.zip”.
– A zipped file will appear in the same location.
• Submit the zipped file.
8
Transfer A VB.NET Project
• Load your project onto a different
computer.
• Method one
– Use a file transfer media, e.g. a flash drive.
– Copy and paste the whole project folder or the
zipped file onto the media.
– Copy and paste the project folder or zipped file
onto another computer.
• Method two
– Upload the zipped file onto Oncourse or send
the file via email attachment.
– Download the file onto
another computer.
9
Unzip A VB.NET Project
• Load the zipped file into a desired location.
• Right click on the file, “Extract All” or
“Extract Here”.
• Click on the solution file to open the
project.
10
Download