IF YOU ARE ACCUSTOMED TO using an earlier version of VB, then the .NET IDE
(integrated development environment)—Visual Studio .NET—will look somewhat
familiar. The concept of a rapid application development (RAD) tool with
controls that you to drag onto forms is certainly still there, and pressing F5 will
still run your program, but much has changed and mostly for the better. For
example, the horrid Menu Editor that essentially has been unchanged since VB1
has been replaced by an in-place menu editing system that is a dream to use (see
Chapter 8).
Also, VB .NET, unlike earlier versions of VB, can build many kinds of applications
other than just GUI-intensive ones. For example, you can build Web-based applications,
server-side applications, and even console-based (in what looks like an
old-fashioned DOS window) applications. Moreover, there is finally a unified
development environment for all of the “Visual” languages from Microsoft. The
days when there were different IDEs for VC++, VJ++, Visual InterDev, Visual Basic,
and DevStudio are gone. (Actually, Visual Interdev is now subsumed into VS
.NET.) Another nice feature of the new IDE is the customization possible via an
enhanced extensibility model. VS .NET can be set up to look much like the IDE
from VB6, or any of the other IDEs, if you like those better.
The purpose of this chapter is to give you an overview of the IDE, not to bore
you to death with details. The best way to get comfortable with the IDE is to use it,
working with the online help as needed. We suggest skimming this chapter and
returning to it for reference as needed. Also, note that the parts of the IDE that are
connected with specific programming elements such as GUI design are covered
in greater depth in later chapters.
(integrated development environment)—Visual Studio .NET—will look somewhat
familiar. The concept of a rapid application development (RAD) tool with
controls that you to drag onto forms is certainly still there, and pressing F5 will
still run your program, but much has changed and mostly for the better. For
example, the horrid Menu Editor that essentially has been unchanged since VB1
has been replaced by an in-place menu editing system that is a dream to use (see
Chapter 8).
Also, VB .NET, unlike earlier versions of VB, can build many kinds of applications
other than just GUI-intensive ones. For example, you can build Web-based applications,
server-side applications, and even console-based (in what looks like an
old-fashioned DOS window) applications. Moreover, there is finally a unified
development environment for all of the “Visual” languages from Microsoft. The
days when there were different IDEs for VC++, VJ++, Visual InterDev, Visual Basic,
and DevStudio are gone. (Actually, Visual Interdev is now subsumed into VS
.NET.) Another nice feature of the new IDE is the customization possible via an
enhanced extensibility model. VS .NET can be set up to look much like the IDE
from VB6, or any of the other IDEs, if you like those better.
The purpose of this chapter is to give you an overview of the IDE, not to bore
you to death with details. The best way to get comfortable with the IDE is to use it,
working with the online help as needed. We suggest skimming this chapter and
returning to it for reference as needed. Also, note that the parts of the IDE that are
connected with specific programming elements such as GUI design are covered
in greater depth in later chapters.
Getting Started
Users of earlier versions of VB (like us, for example) will probably want the IDE to
resemble and work like the traditional VB6 IDE as much as possible. You can do
this by selecting Visual Basic Developer from the Profile dropdown list on the My
Profile link on the VS home page, as shown in Figure 2-1.
Notice that you can also customize the keyboard and the window layout for the
IDE, and that you can save these in different profiles. You can always change your
profile by going to Help|Show Start Page and then choosing My Profile.
In VB .NET, every project is part of what Microsoft calls a solution. You cannot
do anything in the VB .NET IDE without your code being part of a specific solution.
Think of a solution as the container that holds all information needed to compile
your code into a usable form. This means a solution will contain one or more
projects; various associated files such as images, resource files, metadata (data
Figure 2-1. Visual Studio home page
The VB .NET IDE: Visual Studio .NET
13
that describes the data in your program), XML documentation; and just about
anything else you can think of. (People coming from VB5 or 6 should think of a
solution as analogous to a program group.) Although solutions are cumbersome
at first, and in all honesty are always cumbersome for small projects, once you get
used to using solutions, enterprise development will be much easier. This is
because with a solution-based approach you can more easily dictate which files
you need to deploy in order to solve a specific problem.
Creating a New Solution
The first step in creating a new solution is to select File|New. At this point you have
two choices: create a New Project or a Blank Solution. Note that even when you
choose New Project, you get a solution. The difference is that the VS .NET IDE
builds a bunch of bookkeeping files and adds them to the solution container if
you choose a specific type of project. (The kind of files you get depends on what
kind of project you choose.)
Most of the time you will choose New Project. When you do so, you will see a
dialog box like the one shown in Figure 2-2, where we scrolled roughly halfway
through the list of possible projects. This dialog box shows the many different
kinds of projects VB .NET can build. (As we write this, there are ten types.) These
project templates work in much the same way as templates did in VB6. For
example, they often contain skeleton code but always contain bookkeeping information
such as which files are part of the solution.
Users of earlier versions of VB (like us, for example) will probably want the IDE to
resemble and work like the traditional VB6 IDE as much as possible. You can do
this by selecting Visual Basic Developer from the Profile dropdown list on the My
Profile link on the VS home page, as shown in Figure 2-1.
Notice that you can also customize the keyboard and the window layout for the
IDE, and that you can save these in different profiles. You can always change your
profile by going to Help|Show Start Page and then choosing My Profile.
In VB .NET, every project is part of what Microsoft calls a solution. You cannot
do anything in the VB .NET IDE without your code being part of a specific solution.
Think of a solution as the container that holds all information needed to compile
your code into a usable form. This means a solution will contain one or more
projects; various associated files such as images, resource files, metadata (data
Figure 2-1. Visual Studio home page
The VB .NET IDE: Visual Studio .NET
13
that describes the data in your program), XML documentation; and just about
anything else you can think of. (People coming from VB5 or 6 should think of a
solution as analogous to a program group.) Although solutions are cumbersome
at first, and in all honesty are always cumbersome for small projects, once you get
used to using solutions, enterprise development will be much easier. This is
because with a solution-based approach you can more easily dictate which files
you need to deploy in order to solve a specific problem.
Creating a New Solution
The first step in creating a new solution is to select File|New. At this point you have
two choices: create a New Project or a Blank Solution. Note that even when you
choose New Project, you get a solution. The difference is that the VS .NET IDE
builds a bunch of bookkeeping files and adds them to the solution container if
you choose a specific type of project. (The kind of files you get depends on what
kind of project you choose.)
Most of the time you will choose New Project. When you do so, you will see a
dialog box like the one shown in Figure 2-2, where we scrolled roughly halfway
through the list of possible projects. This dialog box shows the many different
kinds of projects VB .NET can build. (As we write this, there are ten types.) These
project templates work in much the same way as templates did in VB6. For
example, they often contain skeleton code but always contain bookkeeping information
such as which files are part of the solution.
No comments:
Post a Comment
This is Good Computer Information Blog.they will give
best information about computer.