| Visual Basic .NET for Beginners | |||||||||||||||||
| Part 2: The Visual Studio IDE | |||||||||||||||||
|
The basic idea is the same as VB 6. In a standard Windows Application, you can drag and drop components from the Toolbox onto a design Form. Then you select Properties for components and enter program code into a code window. Like VS 6, VS.NET includes a full featured Debug environment where you can watch your code execute statement at a time. (There is not as much flexibility to change your code and continue executing as there is in VB 6. This is something Microsoft hears complaints about constantly - they call it "Edit and Continue" in their publicity - and they have pledged to fix it in the next major release called, "Whidbey".) Once your program runs the way you want it to, you can Build an executable version of your program. |
|||||||||||||||||
But the "basic idea" doesn't begin to describe the new tricks available! One way to look at all of the new stuff in VS.NET is to classify things into these two categories: The Language Features are the things you have to know about Visual Basic .NET and how to use it in Visual Studio. For example, how to add References, new program Modules, and what all the components in the Toolbox are for. Since "Language Features" are what most of the rest of the .NET focused articles at About Visual Basic are all about - and since this is an introduction to Visual Studio .NET - we're going to focus on the IDE Features in this lesson instead. If you're familiar with the Visual Studio 6 IDE, get ready for some kewl new tricks. In Tabbed Documents mode, the ability to rearrange all of your windows into docked or tabbed windows gives you as much control over how your development environment looks as you could ever wish for. You could undock all of the windows and have one that looks like this. Notice that these new windows overlap the borders of the parent. Microsoft calls these Floating windows. Alternatively, you could dock all of the windows and then drag them to tabbed positions and end up with one "utility window" that looks something like this. All of this is done by dragging and dropping the windows using "click and hold" movements on the Title Bar with the left mouse button. If you haven't done it before, it will probably take some practice before you can do it quickly and easily. Remember ... your "Environment" must be set to Tabbed Documents mode before you can do this. And double clicking the Title Bar will reset the whole thing to tiled windows again. It's a dynamic environment! When you first work with these sticky windows, you may be more confused than anything else. It's often very unclear when windows will dock and where they will dock. The Whidbey release of Visual Studio - due out in a few months - will add a visual indicator on the screen showing you where windows will dock. Another new trick is the use of the Auto Hide "push pin" to move windows to tabs that line up along the sides of the window, or expand out when you sweep the mouse over them. Clicking the push pin will "pin" the window in a displayed position so you can work with it. But if you just wanted to check some information in the window, it disappears back against the sides of the window when the mouse pointer isn't over it. When the window is expanded, you can click and drag the the inside border to make all the information visible just like you would a normal window. This combination makes maximum use of your monitor area while still making all of the windows you need available in a single mouse motion and it's my favorite configuration for working. If a window is floating and you want to move it into an Auto Hide position against one margin, you first have to dock it to the side you want it to be on. Then click the Auto Hide push pin to make it disappear into a tab on that margin. One thing to keep in mind if you're moving windows around a lot is that you can normally only dock windows once they're "pinned" to the desktop. If they're in Auto Hide mode, then you just can't select them and move them around. So if you want to move a window, make sure it's pinned first. If you move a lot of windows to one margin (usually - more than three, depending on your monitor size and settings), you can't see the tabs for some of them because they don't resize automatically like, for example, the Windows XP Task Bar. VS.NET has another trick for this. Right click on the margin and you can select the window you want from a context menu. And finally, after all this experimentation, you might find that you have such a confused configuration of windows, tabs, and pop out menus that you just want to get things back to normal. We've got you covered! Reset your window layout using Tools > Options > Environment > General. Click the Reset Window Layout button. You'll read more about this later, but the next release of Visual Studio - Whidbey - will allow you to export your development settings so you can, for example, install settings from your main development computer into a laptop. |
|||||||||||||||||

After you work with VS.NET, you will be convinced that it's one of the most 'configurable' systems you have ever seen. When you have selected a project to open after configuring options on the Start Page, you will see a screen somthing like this illustration of a typical VS.NET desktop. Since this view still shows only part of the windows that are available to you, it should be enough to convince anyone that it's a complex system just packed full of different programming tools and features.
Buried in the General page of the Environment folder in the Options dialog box under the Tools menu item - (whew!) - you will find a little noticed setting which allows you to work in either Multiple Document Interface (MDI) or Tabbed Documents mode. The default is Tabbed Documents mode and that's what the rest of this lesson will assume. If you select the MDI mode, however, you can tile or cascade the windows but your ability to dock them is lost. If you want something that looks just a little more like the old Visual Studio 6, MDI mode will help, but MDI style windows seem to be losing popularity compared with docking windows.
