In this lesson, you will learn about the options offered by Microsoft Visual Studio 6.0 when installing the Enterprise Edition of Visual C++ 6.0 using a custom installation. The installation setup program is a good place to gain an overview of the features offered by the Visual C++ development environment, as it groups together all the installable options that are available to you in one logically organized, browsable location. If you already have Visual C++ installed, you can still follow through this lesson to further your understanding of the installation options.
After this lesson, you will be able to:Estimated lesson time: 30 minutes
- Understand the choices presented to users when installing Visual C++ 6.0.
Visual C++ comes as part of the Visual Studio development suite or as a stand-alone product. In either case, you start the installation process by running the Setup.exe file from the root directory of the CD.
NOTE
If you are using Windows NT 4.0, you will need to install the Windows NT Service Pack 3 before you can install Visual C++.
First you will be presented with a dialog box providing you with the opportunity to browse the Readme file. This file contains important information that will likely impact your development effort, so you should at least scan its contents.
Next, you will be presented with the user license agreement. Once you have read and accepted the user license agreement and entered your product number and user ID, you will be taken to a dialog box that presents you with setup options. At this point, choose a Custom setup and click Next.
On the screen that appears, accept the default installation location by clicking Next. The setup process will begin. Read the information screens and click Next until you arrive at the Custom Setup screen, shown in Figure 1.8. (This figure displays the Visual Studio version of this screen, which shows options to install the other products in the Visual Studio suite.)
Figure 1.8 The Visual Studio Custom Setup screen
If you already have Visual C++ installed, you'll want to get to the maintenance dialog box that allows you to add or remove components for your current installation. You access this dialog box by selecting the Workstation option. This maintenance dialog box is identical to the setup screen, so you can use it to explore the installation options.
The custom setup screen appears with a default set of installation options selected, which you can change as required. A check mark next to an installation option means that the option will be installed. Many of the options are arranged in a hierarchical order. If one of the items in the Options list is selected and the Change Option button is made available, you can click it to reveal further sub-options beneath the currently selected option. OK and Cancel can be used to move up the option hierarchy, saving or discarding the changes you have made to the option selection on each screen.
If an option check box is selected but shaded, only some of its suboptions are selected, meaning that only some of its options will be installed.
The following exercise shows you how to use the Custom Setup or Maintenance screen to configure your installation options.
Note that the CRT Source code option is not selected. Note, too, that the option requires 5805 KB of disk space. Having the C run-time source code available means that you can use the debugger to step through the C source code of the standard C libraries. If the CRT source code is unavailable, you will only see assembly language instructions when you use the debugger to step into a C library function. Having this source code available can also be instructional in that it demonstrates how professional C programmers handle a particular programming situation.
TIP
If you make changes at one level and click OK, and then click Cancel at a higher level, the lower level changes are still reflected in your setup. If you want to cancel the lower level changes, you must go to the dialog box on which they were made and reverse them, and then click OK in that dialog box.
The rest of this lesson consists of a brief explanation of most of the Visual C++ installation options. Using the Custom Setup or the Maintenance screen, locate each of the options listed in the following sections and determine whether or not you require them to be installed on your computer.
You have an all or nothing choice of options with Visual Studio, and you should hence select the default choice of All. The default choice installs the development environment, wizards, and debugger.
The Visual C++ UI consists of an integrated set of windows, tools, menus, toolbars, directories, and other elements that allow you to create, test, and refine your application in one place. You can also work on other types of documents within Visual C++, such as Microsoft Excel or Microsoft Word documents.
The VC++ Runtime Libraries selection, which you read about in the previous exercise, offers four choices:
Each of the libraries has an optimized release version without debug symbols and a debug version with no optimizations, but with debug symbols. When you choose to include the source code, you can step into library functions during debugging sessions.
Developers of desktop applications on the Win32 platform (that is, Windows 95, Windows 98, and Windows NT) will often want to take advantage of multithreading capabilities offered by these platforms. If you are developing programs that need to run on older 16-bit platforms, you will need to link to the single-threaded CRT libraries.
The MFC Library is a collection of C++ classes that provide a framework for programming on the Windows platform. Building on the work of expert Windows developers, you can quickly and easily generate applications, libraries, and software components. MFC makes rapid development available for all aspects of Windows programming, including the development of UIs, Internet development, component technology, and database access—all without sacrificing programming freedom and flexibility. MFC provides the AppWizard, a step-by-step visual tool that allows the developer to quickly and easily generate frameworks to set up a basic application structure; and to generate code to implement fundamental application behaviors.
The VC++ MFC and Template Libraries option includes the following MFC libraries:
This option is in the same dialog box as the MS Foundation Class Libraries option. Choose MS ActiveX Template Library (ATL) to install the headers, libraries, and source files for ATL.
ATL is a set of template-based C++ classes with which you can easily create Component Object Model (COM) objects. ATL simplifies the often-complicated process of COM development, but with less overhead than MFC. ATL's ability to generate small, fast components is especially useful if you are developing for an Internet environment. ATL has special support for fundamental COM features including stock implementations of key COM interfaces, and helper classes that simplify working with COM objects and data types. COM and ATL are covered in depth later in this book.
The Build Tools option installs the compiler, linker, NMAKE, and other tools used to build applications and components.
The Data Access option is in the main selection dialog box, at the same level as the C++ options. These options include:
OLE DB is a set of interfaces that exposes data from a variety of sources using COM. OLE DB interfaces provide applications with uniform access to data stored in diverse information sources. These interfaces support the amount of DBMS functionality appropriate to the data source, enabling it to share its data.
ADO enables you to write a client application to access and manipulate data in a data source through a provider. ADO is designed as an easy-to-use application level interface to OLE DB providers. ADO's primary benefits are ease of use, high speed, low memory overhead, and a small disk footprint.
RDS client-side and server-side components work together to bring data over the Internet or over an Intranet to a Web page. These RDS components also allow updated information to be sent back across the network and merged into a database.
We suggest that you install the default Data Access options, but consider whether you would ever need to write applications that connect to an ISAM data source using the Jet engine, and look through the Microsoft ODBC Drivers options to see whether the preselected set is likely to meet your needs.
The tools included with the Enterprise Edition of Visual Studio are as follows:
General tools are included with all versions of Visual C++. We suggest that you install all of the following:
On the main installation screen, you will find an option to install Visual SourceSafe 6.0 (VSS). VSS helps you manage your projects, regardless of the file type (text files, graphics files, binary files, sound files, or video files), by saving them to a database. If you need to share files between two or more projects, you can share them quickly and efficiently. When you add a file to VSS, the file is backed up on the database, made available to other people, and changes that have been made to the file are saved so you can recover an old version at any time. Members of your team can see the latest version of any file, make changes, and save a new version in the database.
Lesson 3 in Chapter 2 teaches you how to implement a source-code control system using VSS, so you should ensure that it is installed. During installation, you might be asked to choose between support for the old or new VSS database formats. Generally you should select the newer format—you can upgrade existing VSS databases using the VSS utility DDCONV.EXE
After you have configured your installation by selecting the appropriate op- tions from the main and sub installation screens, you click the button labeled Continue to start installing the software. You will be prompted to reboot your computer to complete the installation. After the reboot, you will be prompted to install the version of the Microsoft Developers' Network (MSDN) library that comes with your copy of Visual C++. You should do this, as the MSDN library is the means by which online Help and documentation are provided for Visual C++.
Visual C++ provides a rich environment for the developer. This environment contains an essential set of tools and utilities to allow you to produce efficient, bug-free code. The libraries and frameworks offered in the environment allow you to create code and application structures for common programming situations, allowing you to concentrate your time and skills on the creation of unique solutions.
The overview of the major installation options provided in this lesson serves as an introduction to many aspects of the Visual C++ development suite that we will cover in more depth throughout this training kit. These include: