Troubleshooting Visual C++ Setup

Debabrata Sarma
Microsoft Technical Support

April 1997

1. Introduction

This article discusses common problems that you may encounter while installing Microsoft® Visual C++®, and it describes, in a logical order, the necessary steps to be followed for troubleshooting setup problems.

Microsoft Visual C++ is available for the 16-bit and the 32-bit programming environment. The 16-bit version can be used both in the 16-bit Windows® operating system (Microsoft Windows versions 3.1 and 3.11[Windows for Work Groups]) and the 32-bit Windows operating system (Microsoft Windows 95 and Windows NT®). The 32-bit version of Visual C++ can be used only in Windows 95 and Windows NT.

The Knowledge Base articles referred to in the text with a Q number are available at http://microsoft.com/kb/default.asp and in the Microsoft Developer Network Library. (Editor's note: when searching the MSDN Library for a Knowledge Base article, be sure to enter the "Q" at the beginning of the query. For example, type Q136258 to find the article Q136258.)

Section 5.8 contains frequently asked questions (FAQs) and their resolution. You may find a quick solution if the problem you are experiencing is listed there. Section 2 contains product history. Sections 2 and 3 discusses the 16-bit product installation. Section 5 contains information about the 32-bit product installation and related FAQs. Network installation issues are covered in section 6. Hardware-related installation problems are discussed in section 7. Section 8 is the conclusion.

2.0 Product History

2.1 16-bit Versions

The first 16-bit versions of Visual C++ are the Standard version 1.0 and the Professional version 1.0. These two versions work in Windows 3.1 and 3.11; neither of them works in Windows 95 and Windows NT 3.51 or 4.0.

The next 16-bit versions are the 1.50, 1.51, 1.52, 1.52b, and 1.52c versions. Versions 1.51 and 1.52 are available only with the 32-bit subscription versions 2.0, 2.1, and 2.2. Version 1.52c is available only with the 32-bit subscription versions 4.0, 4.1, and 4.2. Version 1.52b is a stand-alone version without the Control Development Kit (CDK), but known also as version 1.52, targeted to students learning Visual C++. All these versions run in Windows 3.1, 3.11, Windows 95, and Windows NT. Please refer to Knowledge Base (KB) article Q145669, "A Comparison of Visual C++ Products" for different features available in these versions.

2.2 32-bit Versions

The first 32-bit version of Visual C++ is version 1.0, meant to run on Microsoft 32-bit operating systems. This version runs in Windows NT (in all versions of NT), but does not run on Windows 95.

The 32-bit version 1.0 of Visual C++ contains a product known as Win32s. Win32s is installed in 16-bit operating systems (Windows 3.1 or 3.11), so that a 32-bit application developed in the 32-bit operating system will run properly in the 16-bit operating system.

Version 2.0 is the next released 32-bit version, followed by subscription versions 2.1 and 2.2. These versions run in Windows 95 and Windows NT. Refer to KB article Q145669 for new features available in these versions. Each of these versions contains a corresponding version of Win32s. It is important that the correct version of Win32s is used in the target machine.

The next version is numbered 4.0 to synchronize with the Microsoft Foundation Class Library (MFC) version. This version has a Professional version and a Standard version. The Standard version does not contain all the features of the Professional version and is targeted to student users learning Visual C++. Versions 4.x will not run in Windows NT 3.50, but will run in Windows 95, Windows NT 3.51, and Windows NT 4.0. The Professional version’s subscription releases are versions 4.1 and 4.2. Version 4.2 is available as Professional and Enterprise versions. The Books Online of these versions seen under InfoViewer contain a topic called “New Features” for each of these versions. The Enterprise version contains the extra features SQL Debugging, SQL Editing, and Data View, all nicely explained in the “New Features” topic.

The Professional versions 4.0 and 4.1 contain their corresponding Win32s versions. It is important that the correct version of Win32s is used in the target machine. Because Version 4.2 does not contain a Win32s version, the box contains another CD with versions 4.1 and 1.52c included. Any future versions of Visual C++ will not contain the Win32s product.

The latest 32-bit version of Visual C++ is Version 5.0. Microsoft Visual C++ version 5.0 is available in three editions: Learning, Professional, and Enterprise. This version will run only in Windows 95 and Windows NT version 4.0 and above. Each edition is hosted in the development environment, which has its own What's New documentation:

3.0 Installing and Troubleshooting the 16-bit Version

The 16-bit versions of Visual C++, versions 1.0 and 1.5xx, are designed to run under the 16-bit Windows operating system 3.1 and 3.11. All versions of 1.5xx will also run in Windows 95 and Windows NT. Since troubleshooting technique is somewhat different for the 16-bit and the 32-bit operating system, we will discuss them under separate sections.

3.1 Installation in Windows 3.1 or 3.11

3.1.1 Running Setup

Since Setup is a Windows application, you must be running the Windows operating system to launch it. Setup can be run from either the File Manager File/Run menu (or by double clicking the setup.exe entry on the product directory) or from the Program Manager File/Run menu. Use of File/Run has the advantage that you can use the following switches, which may be useful sometimes for troubleshooting purposes.

/F  Do not copy files. This may be useful for recreating the program group or modifying the system.ini file.

/L  Log file copies. This creates a log file with .log extension in the \msvc\bin directory. This file lists all the files setup intends to copy from the source to destination. It then lists all the files actually copied.

/O  Make no configuration changes. Do not change system.ini or tools.ini.

/P  Make no Program Manager changes. Do not add or change the program group.

You will find that the switches /F and /L are very useful.

3.1.2 Selecting options

When you start Setup you will get a screen titled “Installation Options”. In this screen, you have buttons for Typical Installation, Custom Installation, Minimum Installation, and Directories. If you click on the Directories button, you will see the listed default directories where the product will be installed. You can change the default settings by editing the listed directories. To familiarize with what is selected by default, and what you may want to install, choose Custom Installation and select the buttons Libraries, MFC Files, Tools, Help Files, Samples, OLE SDK, and Drivers. Before continuing with setup, you can go back and forth using the Back or Cancel button to familiarize yourself with what is available You may use the Help button to get more information on these topics. Once you continue with setup, and if everything goes well, you will get the “Setup Complete” screen. This screen contains the following text:

“If you wish to run the Microsoft C++ Compiler from the command line, you need to run MSVCVARS.BAT. This will set your PATH, INCLUDE, and LIB environment variables so that they contain the appropriate directories.”

MSVCVARS.BAT file will be in MSVC\BIN directory. Execute this file from the MS-DOS® command line so that you can run the utilities (CL, LINK, NMAKE, etc.) from the MS-DOS command line from any directory. You will be using this quite a lot during setup troubleshooting. From Windows, go to the MS-DOS prompt by exiting Windows, or go to the Windows MS-DOS shell from the Main Program group. Find the MSVCVARS.BAT file in the MSVC\BIN directory. Run the “SET” command (without the quotes) from the command line, run the MSVCVARS.BAT file, and then run the “SET” command again. You will notice that the environment variables are all changed.

3.1.3 Testing the installation

After installation is completed successfully, you need to run some tests to check for proper installation. Start the Visual C++ Workbench. You may want to do all or at least two of the following.

  1. Build, execute, and debug the Windows “Generic” sample.

  2. Build, execute, and debug the MFC “Hello" sample.

  3. Build, execute, and debug a default AppWizard-created project.

  4. Build, execute, and debug a Quickwin application or an MS-DOS application, printing “Hello World”.

To debug, set a breakpoint in your code and select Debug Go (or press the F5 key). For a quick verification, the debug step may be excluded.

Note   to debug an MS-DOS application, you need to use CodeView for MS-DOS from the Tools menu.

3.1.4 Troubleshooting

Microsoft Visual C++ installs and runs correctly on most systems without any problem. However, on a small number of systems setup problems occur, which may include system crashes or hangs, or inability to complete the build operation. The problem is caused by hardware or software conflicts. Visual C++ uses system resources very heavily. Therefore, it may hit problem areas not exposed to other applications. Currently, the number of setup issues in 16-bit operating systems is showing a downward trend with the increase in use of the Windows 95 operating system.

Some hardware problems could be due to bad memory (internal cache/external cache, motherboard RAM), bad motherboard (bad CPU, defective fan, bad bus termination), bad disk drive or disk controller, bad CD-ROM or CD-ROM controller, or a bad CD.

Software problems could be device driver conflicts, such as third-party device drivers, Windows device drivers, network drivers, and conflicting terminate-and-stay-resident (TSR) applications.

Therefore, we need to isolate whether it is a hardware problem or a software problem.

3.1.4.1 Failed to install

If installation fails to complete—for example, it is unable to complete certain operations, hangs in the middle of setup, or exhibits unpredictable behavior, then (as stated before) it could be either a hardware problem or a software problem. For hardware problems, refer to the section on “Hardware Troubleshooting,” which applies to both the 16-bit and the 32-bit operating systems.

Software problems arise from obsolete device drivers or device driver conflicts in memory. For example, if a SCSI hard drive is used, then make sure that the updated versions of the ASPI2DOS.SYS and ASPIDISK.SYS are used. All manufacturers maintain a Web page and make available the latest drivers for downloading by customers. The same applies to the CD-ROM driver. Another problem area is the video driver. Try the following steps to resolve driver conflicts. Run Setup after each step.

  1. Change the video driver to VGA mode. To do this, from the Main program group select the “Windows Setup” icon. From the Options menu, select “Change System Settings”. Then, from the Display drop-down box, select VGA mode.

  2. Remove all applications from the Startup group.

  3. Check whether File Access and Disk Access is set for 16-bit. You can find this out or change the settings by opening Control Panel in the Main program group, then selecting the “386 Enhanced” icon, then selecting the Virtual Memory button followed by selecting the Change button.

  4. Try with a clean-boot system. This requires a minimal AUTOEXEC.BAT, CONFIG.SYS, and a SYSTEM.INI file. Most problems go away with a clean AUTOEXEC.BAT and CONFIG.SYS file. So, try these out first. Save the old files with different names for restoring them after setup is successfully completed. See the following KB articles for more information: Q124789, "How to Create a 'Clean Boot' Disk to Troubleshoot Problems," and Q117674, "How to Create SYSTEM.INI Without Third-Party Drivers."

    It is to be noted that with a clean AUTOEXEC.BAT and CONFIG.SYS file, the CD-ROM drive will not be accessible. To install the CD-ROM driver you need to add a command line in each of these files. Look at the saved files and find the two lines and copy them in the respective files.

    The two examples below from two different systems give an idea of how they look. The common factor here is the MSCDEX.EXE file that comes with the Windows operating system, and the value with the /D switch, which is the same in both files. Other switches are suggested by the manufacturer in their CD-ROM manual. Sometimes, changing these switches may also make a difference. Contacting the manufacturer’s support line may also help. The CD-ROM drivers in the two examples below are MTMDAI.SYS and SBCD.SYS, respectively.

    Example 1:

    In the AUTOEXEC.BAT file:

    LH  /L:1,36224  C:\DOS\MSCDEX.EXE  /D:MTMIDE01  /M:10

    In the CONFIG.SYS file:

    devicehigh  /L:1,13216 =C:\MTM\MTMDAI.SYS  /D:MTMIDE01  /P:170,15

    Example 2:

    In the AUTOEXEC.BAT file:

    LH C:\SB16\DRV\MSCDEX.EXE  /D:MSCD001  /V  /M:15

    In the CONFIG.SYS file:

    DEVICEHIGH=C:\SB16\DRV\SBCD.SYS  /D:MSCD001  /P:220

    If this step succeeds, then you need to find the offending driver by restoring the old files one command line at a time. Once you find the offending driver, try to resolve the problem by contacting the manufacturer. Else, keep two sets of files and boot the system with the required set to use Visual C++.

  5. Using File Manager, find the MSVC.EXE file in the CD-ROM directory. Run or double-click this file. If Visual C++ Workbench comes up, then the CD is not a problem. You can also look for scratch marks in the CD or clean it with a moist cloth and then try again. If another system is available, try the CD in that system to see if it works. This will verify whether or not the CD is the problem.

  6. If there is enough hard-drive space available, copy the MSVC directory from the CD to your hard drive using the command “XCOPY /S” (without the quotes) from the MS-DOS command line. Then try installing from the hard drive, choosing a directory other than the one you copied the MSVC directory. For example, if the copied directory has the path C:\MSVC, then install in a directory C:\LANG\MSVC or D:\MSVC, if you have a D:\ partition. After a successful installation, you can delete the copied directory.

If none of the above resolve the installation problem, try the hardware troubleshooting section.

3.1.4.2 Installation succeeded, but doing a build creates a problem

KB article Q102333, "Troubleshooting Visual C++: Setup and Build Process," describes the steps to follow to figure this out. Again, this could be a hardware problem or a software problem. You should try all the steps in this article and become very familiar with what each step is doing. This is a very useful article.

If you pass Step 1 of this article, then you are half way through in your troubleshooting, because this indicates that it is not likely to be a hardware problem. Continue with Step 2 to resolve the problem. At this point, you may need to consult the article for a clean AUTOEXEC.BAT, CONFIG.SYS, and a minimal SYSTEM.INI file. Most problems go away with a clean AUTOEXEC.BAT and CONFIG.SYS file. So, try these out first. Also, make sure that the following two lines are present in the AUTOEXEC.BAT file:

SET TEMP=C:\TEMP
SET TMP=C:\TEMP

and that TEMP is a valid sub directory under C:\.

If the above steps does not resolve the issue, then do a File Compare of files in the MSVC\BIN directory in the hard drive with that in the CD-ROM MSVC\BIN directory. The command to use from the MS-DOS command line is:

FC /B  C:\MSVC\BIN\*.*   E:\MSVC\BIN\*.*  

where E:\ is the CD-ROM drive. You will find differences only in the following files:

If File Compare detects other files to be different, then manually copy the affected files from the Visual C++ CD. If this does not resolve the problem, delete the whole MSVC directory from the hard drive and reinstall Visual C++. Before that, you may run CHKDSK or SCANDISK (if available) on the hard drive. If this does not resolve the issue, then there could be corrupted files in the Windows operating system, or it could be a hardware problem, or the CD may be bad. If there is another machine available, then the CD can be used to install Visual C++ in the other machine and confirm that the CD is not bad.

At this point, it is better to try the hardware troubleshooting steps (Section 7.0), because you may want to delay the prospect of reinstalling the Windows operating system. If the hardware troubleshooting does not reveal any problem, delete the MSVC directory and reinstall Windows 3.1 or 3.11, and reinstall Visual C++. Reformatting the hard drive before reinstalling the Windows operating system could be another option.

4.0 Installing in Windows 95 and Windows NT

Installation of the 16-bit version of Visual C++ on Windows NT usually results in no problems. Most of the problems occur on Windows 95. It is to be noted that CodeView for Windows does not run on Windows NT.

The first three sections discussed above—Running Setup, Selecting Options, and Testing the Installation—apply here too. Use Explorer, Start/Run, or File Manager (NT 3.5x) to run setup.

4.1 Windows 95 Real Mode and Protected Mode CD-ROM Driver

The CD-ROM driver installed in Windows 95 can be of Real Mode or of Protected Mode type. A Real Mode driver is a left-over from the 16-bit world, whereas the Protected Mode driver is the Windows 95 operating system’s preferred type of driver. To find out whether you have a Real or a Protected Mode driver, check to see if the AUTOEXEC.BAT file has an unremarked MSCDEX.EXE entry that indicates the presence of a Real Mode driver. Or, open Control Panel and double-click the System icon. Click the Device Manager tab. You will see all the devices connected to your computer. A yellow blob with an “!” mark is an indication that the device has some problem in functioning properly. If you see CD-ROM Controller and CD-ROM drive entries listed in the tree, then you have a Protected Mode driver. Expanding on the ‘+’ sign and then double-clicking on the expanded item will lead to the Property Page of the CD-ROM Controller or the CD-ROM drive, giving valuable information through the tabs about the device and the driver used, and whether they are functioning properly or not. If there is an indication that the device is not functioning properly, then you should contact the manufacturer of the device for the proper driver. All the manufacturers maintain an Internet Web page where information about the product, latest available drivers, and download information are available.

4.2 Troubleshooting in Windows 95 and Windows NT

As explained above, setup problems could be due to device-driver conflicts or to hardware problems. What we are going to discuss in this section also applies to setup problems for the 32-bit versions of Visual C++.

4.2.1 Failed to Install

If installation failed, then try the following. It is advisable that you close all applications during setup. When you get the first setup screen, close all applications, including Explorer or the MS-DOS box. Try installing Visual C++ after completing each step.

Steps 1, 2, 4, 5, and 6 in section 3.1.41 apply here too. Read the following before trying these steps.

For Step 1, to change to VGA mode, from Control Panel, double click the Display icon, select the Settings tab, select Change Display (or for Windows NT the “Display Type “button, select Change button in Adapter Type. In Windows 95, select the Show all devices button. Choose Standard display types and select VGA.

Step 2 in section 3.1.41 is applicable as is.

Note that Step 4 is applicable to Windows 95 only, not to Windows NT. In Windows 95, you can rename the AUTOEXEC.BAT and the CONFIG.SYS file as AUTOEXEC.BA2 and CONFIG.SY2, and when the system is rebooted, Windows 95 will come up and none of the drivers or applications loaded through AUTOEXEC.BAT and CONFIG.SYS will be loaded. But, if the CD-ROM driver used is a Real Mode driver and is loaded through the AUTOEXEC.BAT and CONFIG.SYS files, then you will not be able to access the CD-ROM drive. You can simulate a clean boot situation if you follow Step 4, create the AUTOEXEC.BAT and the CONFIG.SYS files, add the CD-ROM driver command lines, and use the file SYSTEM.CB for a clean SYSTEM.INI file. Windows 95 provides a file called SYSTEM.CB as a template for a clean SYSTEM.INI file. Rename your current SYSTEM.INI file (for example, to SYSTEM.ORG), copy SYSTEM.CB to SYSTEM.INI, and add the following lines to the sections shown (otherwise, use of the mouse will not be available). With this SYSTEM.INI, Windows 95 starts in VGA mode:

[386Enh]
mouse=*mouse, msmouse.vxd
[boot]
drivers=mmsystem.dll
mouse.drv=mouse.drv

For Step 5, if you are using Windows 95 and Windows NT 4.0, use Explorer instead of File manager. You may also use Start/Run or File/Run (in Windows NT 3.5) as appropriate to start the MSVC.EXE file.

For Step 6, after copying the files, and if you are using Windows 95, then install Visual C++ in Windows 95 Safe mode. Safe mode installs only the minimum required drivers to run Windows 95 and starts in the VGA mode. Therefore, under Safe mode you cannot access the CD-ROM drive. To get into Safe mode, reboot the system and press the F8 key when you see the message “Starting Windows 95 . . .” Select “Safe mode” from the displayed menu.

Note that in Safe mode, the hard disk driver used by Windows 95 is the Real mode driver. If you can get a successful install in Safe mode, this may mean a problem in the hard disk driver or controller, or a conflict with other third-party drivers. In the regular mode Windows 95, the 32-bit protect-mode disk drivers can be disabled in the Troubleshooting tab of File System Properties under the Performance tab of System Properties.

If it is absolutely necessary to get access to the CD-ROM drive in Safe mode, it is possible to do so by loading a Real mode CD-ROM driver. See the following for details.

Running Windows 95 in Safe mode with a CD-ROM drive

The first step below is applicable only if Windows 95 is installed on a previous version of a 16-bit Windows operating system. Otherwise, make sure that the Autoexec.bat and the Config.sys files contain the lines shown in Example 1 or 2 as described in Step 4 above, and skip the first step below.

  1. Enable the real-mode device drivers for the CD-ROM drive as follows:

    a. Click the Start button and then click Run.

    b. In the Open box, type sysedit and then click OK.

    c. Delete the REM statement in front of the MSCDEX.EXE line in the Autoexec.bat.

    d. On the File menu, click Save.

    e. On the Windows menu, click Config.sys.

    f. Delete the REM statement in front of the CD-ROM device driver line in Config.sys.

    g. On the File menu, click Save.

  2. Click the Start button, click Shut Down, select Restart Computer, and then click OK.

  3. When "Starting Windows 95..." appears, hold down the F8 key until you see a Windows Startup menu.

  4. Choose the option Command Prompt Only. This will process the Autoexec.bat and Config.sys and load the real-mode CD-ROM device drivers that were re-enabled in Step 1.

  5. At the command prompt, start Windows into Safe mode by typing win /D:M (start Windows 95 with a minimal set of Windows drivers).

    NOTE:   If networking components are required to start Windows 95 (not recommended for setup trouble-shooting), type the following line instead of the line above:

    win /D:N

If the problem does not occur when you start Windows 95 in this manner, you have determined that the real-mode and protected-mode configuration conflict. If installation is successful at this stage, test the installation in this mode and test again by rebooting in the regular mode.

Consult the following two KB articles to learn more about Windows 95 Safe mode trouble-shooting:

If none of the above resolve the installation problem, try the hardware troubleshooting section.

4.2.2 Installation Succeeded but Problem Doing a Build

If installation is successful but it failed to start the Visual C++ Workbench (also known as the IDE), or failed to build a simple application, try the following:

  1. Use Notepad or your favorite editor to write the following simple program and save this as main.c file in a test directory created for this purpose.
    #include <stdio.h>
    void main(void) 
    
    {
             printf ( “Hello World”);
    }
    
  2. Run the MSVCVARS.BAT file in the MS-DOS command line from the MSVC\BIN directory.

  3. From the MS-DOS command line go to the test directory and run the following command:
    CL main.c
    

    If successful, this will create the EXE file main.exe and you can verify the program output by executing this file. This proves that the compiler and the linker batch utilities are running properly. To further strengthen this finding, you may try to build the MFC HELLO sample in the SAMPLES directory by running the following command and executing the HELLO.EXE if the build is successful.

    NMAKE /BD /F HELLO.MAK
    

    The /B switch starts the build if time stamps are equal, and the /D switch displays build information, which is helpful for diagnosis purpose. Success here means the command line utilities are functioning properly.

    Failure at this stage means that there is device driver conflict or hardware problem for the IDE to run under Windows. In either case we need to go to the next step.

  4. At this point, we need to try the steps discussed in the “Failed to Install” section above and the following two KB articles, one written for Windows 95 (article Q134347, "Troubleshooting Visual C++ Setup Problems Under Windows 95") and the other for Windows NT (article Q136258, "Troubleshooting Visual C++ Setup Problems in Windows NT."

If the problem does not resolve after trying all of the above, try the hardware troubleshooting steps discussed below in section 7.0. If the problem still persists, then reinstall Windows 95 and try installing Visual C++. It is to be noted that reinstalling Windows 95 does not require reinstallation of all the other software installed before. Try the following steps to reinstall Windows 95.

Click the Start button, click Run, type the path to the Windows 95 Setup program in the Open box, and then click OK. For example, if your Windows 95 CD-ROM is in drive D, type the following line:

d:\setup

Or, if you are using Windows 95 disks, insert disk 1 in drive A and then type the following line:

a:\setup

When the Setup dialog box appears, click Continue and follow the instructions to set up Windows 95 again. If you see the "Restore Windows files that are changed or corrupted" option, choose it. If you do not see this option, choose to reinstall Windows 95.

If you are using Windows NT, install the latest Service Pack.

5.0 Installation and Troubleshooting the 32-bit Version

As we mentioned before, the 32-bit versions of Visual C++ run only in Windows 95 and Windows NT. You need administrative privileges in Windows NT to use all the features (ActiveX controls) of Visual C++ Version 4.x. See KB article Q155059, "PRB: Need Design-Time License for Microsoft ActiveX Controls" for more information.

Visual C++ version 5.0 will fail to install in Windows NT without administrative privileges. This is because Version 5.0 needs Internet Explorer, and without administrative privileges Internet Explorer will not install. You get the following message when you start the setup program:

“Setup detects that you are not a member of the Administrator group, which is required for installing ODBC, ActiveXRPC debugging, Internet Explorer, and Just-in-Time debugging. Continue ?”

5.1 Windows 95 Real Mode and Protected Mode CD-ROM Driver

A real mode driver can be used to install Visual C++ up to version 4.2. There are some files in version 4.2 that are more than 8 characters long. You will get a message that these files could not be copied. To resolve this issue, refer to KB article Q154045, "Setup Cannot Access the Source File ...\include\ALGORITHM." Visual C++ version 5.0 installation requires a protected mode CD-ROM driver.

5.2 Running Setup

Starting from Visual C++ version 4.0, there is a master setup.exe file in the root directory and a Visual C++ setup.exe file in the MSDEV directory. Master setup allows you to select the Visual C++ setup and others. Similarly, for version 5.0, the master setup.exe file is in the root directory and the Visual C++ 5.0 setup.exe file is in the DEVSTUDIO directory. If you use the Start/Run command (available in Windows 95 and NT 4.0) or an MS-DOS box to run the Visual C++ setup.exe file, you can use the following options.

/F Do not copy files. This may be useful for recreating the program group or modifying the system.ini file.

/L Log file copies This creates a log file with .log extension in the \msvc\bin or ...\Vc\bin directory. This file lists all the files setup intends to copy from the source to destination. It then lists all the files actually copied.

/O Make no configuration changes.

/P Make no Program Manager changes. Do not add or change the program group.

/R Do not register DLLs and ActiveX (only in Visual C++ 5.0) controls.

It is advisable that you close all applications while running setup. Consult KB article Q148882, "Visual C++ 4.0 or 4.1 Setup Fails to Copy Shared DLLs" if setup fails to copy some files (DLLs, etc.) during installation of Visual C++ version 4.0 and 4.1.

5.3 Selecting Options

The installation screen has buttons for Typical Installation, Minimum Installation, CD-ROM Installation, Custom Installation, and Directory. If you click on the Directory button, you will see the listed default directories where the product will be installed. You can change the default settings by editing the listed directories. The amount of disk space required for each installation is also displayed. Depending on your requirement and system resources available, you need to choose one of these installation categories. It is always advisable to select the Custom Installation option and navigate back and forth using the Next and Back buttons to find out what is available. Using this information, you can pick the type of installation you need and proceed with setup. If setup is successful, you will get the following message in a “Setup Complete” screen:

“For your convenience, the environment variables required to build tools from a command prompt are saved in VCVARS32.BAT in your BIN directory.”

For Visual C++ version 4.x, this batch file is created in the ...\MSDEV\BIN directory, and for Visual C++ version 5.0 this is in the ...\DevStudio\Vc\BIN directory. Run this file from the MS-DOS box to use the command-line utilities CL, LINK, and so on.

Before or after installation, it is always advisable to read the file Vcread.wri in the ...\MSDEV directory if you are installing Visual C++ version 4.x, and the files Vcread.htm, environ.htm, and Readmedt.htm in the ...\DevStudio\Vc directory if you are installing Visual C++ version 5.0. These files contain valuable information about the product that you should know before using or installing it.

5.4 Run Setup with /F switch

If you want to install Visual C++ in a dual-boot machine like Windows NT and Windows 95, you should first run the full setup in one operating system. Then in the other operating system you can run setup with the /F switch, selecting the same setup options and directory so that only one copy of the installed files exist in the hard drive. Note that both operating systems should be able to read the installed disk directory file system (e.g., FAT). Use the MS-DOS command prompt or Start/Run to run the command “setup.exe /F” (without the quotes) from the corresponding CD-ROM directory. This way setup will create the proper program group with icons and create the registry entries. If they are not already copied, you need to copy from the CD-ROM the sub directories ...\Vc\ Bin\Win95 and ...\Vc\Bin\WinNT to the corresponding ...\Vc\Bin\ directory in your hard drive installation.

If you have more than one user account, you need to run setup with the /F switch once for each user log-on so that only one copy of Visual C++ is maintained in the hard drive.

If the registry entries get corrupted, you can run setup with the /F switch after deleting the “Developer” or the “DevStudio\5.0” registry key for version 4.x or 5.0 respectively, from HKEY_CURRENT_USER\Software\Microsoft and HKEY_LOCAL_MACHINE\Software\Microsoft. This will recreate the registry key.

Note that the file MSDEV.EXE contains the information about User Name and User Organization and displays them during startup and in Help About, though the following two registry keys also contain these values. Thus, changing or deleting the following keys will not change User Name and User Organization. For that reason, if you run MSDEV.EXE from the CD-ROM, Unauthorized User and Unlicensed Copy are displayed. You can always change User Name and User Organization by running setup.exe with the /F switch.

HKEY_CURRENT_USER\Software\Microsoft\Developer\Setup
HKEY_LOCAL_MACHINE\Software\Microsoft\Developer\Setup

In Visual C++ 5.0, “DevStudio\5.0” replaces “Developer”.

5.5 Testing the Installation

After installation is completed successfully, you need to run some tests to check for proper installation. Start the Visual C++ Integrated Development Environment (IDE), also known as Visual C++ Workbench, or Developer Studio (version 4.x and 5.0). To start it, you have to click on the program icon Microsoft Visual C++, or Microsoft Developer Studio from the Microsoft Visual C++ Program Group. You may want to do all or at least two of the following:

To debug, set a breakpoint in your code and select Debug Go (or press the F5 key). For a quick verification, the debug step may be excluded.

5.6 Troubleshooting

As we mentioned earlier, installation problem may occur due to hardware or software conflicts. The following two articles contain most of the troubleshooting techniques for Windows 95 and Windows NT. These two articles are also available in the PSS.HLP file in the ...\MSDEV\HELP directory if you are using Version 4.x. The file can be read off the CD-ROM without installing Visual C++ by double-clicking the file from Explorer or File Manager.

5.6.1 Failed to install

If installation failed, try the troubleshooting techniques described in the above two articles.

All the information provided in an earlier section (section "4.2.1 Failed to install") applies here also. If you are installing Visual C++ version 5.0, then the discussion about the Real mode CD-ROM driver does not apply. Check this section and see if there are additional suggestions to try that are not listed in the above mentioned articles.

If the problem still exists, try the hardware troubleshooting steps discussed in Section 7.0 below.

5.6.2 Installation succeeded but problem doing a build

At this point, installation is successful, but it is not possible to get a successful build of a project or there are problems bringing up the IDE or its use. Try all the steps suggested in section "4.2.2 Installation succeeded but problem doing a build.” The only difference is that to run the command-line utilities, run the file VCVARS32.BAT from the ...\MSVC\BIN\, or the ...\MSDEV\BIN\, or the ...\DevStudio\Vc\BIN directory, for versions 2.x, 4.x, and 5.0 respectively. The KB article Q154289, "How To Identify the Symptoms of File Corruption Problems," contain valuable information about file corruption problems in Visual C++.

The following files will be different if you compare the files in the hard drive ...\BIN directory with the corresponding files in the CD-ROM ...\BIN directory:

Visual C++ version 2.x
MSVCSHL.DLL, SPYXX.EXE

Visual C++ version 4.x
MSDEV.EXE, SPYXX.EXE, \IDE\MSVCCPP.PKG

Visual C++ version 5.0
There are two BIN directories in version 5.0 install. They are ...\DevStudio\SharedIDE\BIN and ...\DevStudio\Vc\BIN. During setup, the installation program binds all the EXEs for address fix up, so that the start up is faster. For this reason, the EXEs in the installed drive will not compare equal with the EXEs in the CD-ROM. Therefore file comparison after installation in version 5.0 is of no use.

5.7 Proper Uninstall for Reinstall

It may be necessary to uninstall and reinstall the product for troubleshooting purposes. In Windows 95 and Windows NT 4.0, if you go to Control Panel from Start\Settings, you will find an icon named Add/Remove Programs. Double-clicking this icon and selecting the Install/Uninstall tab will show the list of applications installed on the system. You can select an application and click the Add/Remove button to uninstall the application from your system. Visual C++ versions 4.x and 5.0 only are listed in the Add/remove properties dialog box. The listed names for Visual C++ are Microsoft Visual C++ (for Version 4.x Professional), Microsoft Visual C++ Standard (for Version 4.0 Standard), and Microsoft Visual C++ 5.0. Close all applications on the desktop before proceeding with the uninstall. If during uninstall you get a message asking you if want to remove a file that has been found to be used by another application, select “Yes to all.” After uninstall is complete for version 4.x, check the ...\Msdev or ...\Msdevstd directory and delete all the subdirectories under it except the Projects directory and the Template directory in case you have created some projects that you want to keep. If it is version 5.0, then delete all the subdirectories under ...\Program files\DevStudio\ except the ...\DevStudio\MyProjects, ...\DevStudio\SharedIDE\AddIns, ...\DevStudio\SharedIDE\Template, and ...\DevStudio\SharedIDE\macros, in case you want to keep projects, macros, and so on that you may have created in these directories.

If you also installed Visual J++™ from the Visual Studio 97 package, uninstall Visual J++ first before uninstalling Visual C++ 5.0. You may see problems in the Visual C++ debugger if Visual C++ and Visual J++ are not correctly installed.

You need to delete the following registry keys also, in case the uninstall program did not delete them. To start the registry editor, type regedit in the Start\Run edit box and press OK if you are using Windows 95 or Windows NT 4.0. In Windows NT 3.5x, run regedt32.exe from the windows SYSTEM32 directory.

Version 4.x

HKEY_CURRENT_USER\Software\Microsoft\Developer
HKEY_CURRENT_USER\Software\Microsoft\InfoViewer
HKEY_LOCAL_MACHINE\Software\Microsoft\Developer
HKEY_LOCAL_MACHINE\Software\Microsoft\InfoViewer

Version 4.0 (Standard)

HKEY_CURRENT_USER\Software\Microsoft\DeveloperStd
HKEY_CURRENT_USER\Software\Microsoft\InfoViewer
HKEY_LOCAL_MACHINE\Software\Microsoft\DeveloperStd
HKEY_LOCAL_MACHINE\Software\Microsoft\InfoViewer

Version 5.0

HKEY_CURRENT_USER\Software\Microsoft\DevStudio\5.0
HKEY_LOCAL_MACHINE\Software\Microsoft\DevStudio\5.0
HKEY_CURRENT_USER\Software\Microsoft\InfoViewer\5.0
HKEY_LOCAL_MACHINE\Software\Microsoft\ InfoViewer\5.0

It is to be noted that Visual C++ version 5.0 is also included in the package known as Visual Studio 97, which also contains Visual J++ version 1.1, Visual Basic 5.0, MSDN Library Visual Studio 97 Edition, and Visual FoxPro™ 5.0. Each of these products when installed will have their registry keys under ...\DevStudio and ...\InfoViewer\5.0. Therefore, if you delete these keys to reinstall Visual C++ 5.0, you need to reinstall the other products. The reinstallation of the other products can be done on top of the existing installation, which will save file-copy time.

Version 2.x

To uninstall version 2.x, delete the ...\MSVC directory and delete the following key from the registry. If you do not want to reinstall version 2.x, you need to manually delete the Program Group.

HKEY_CURRENT_USER\Software\Microsoft\Visual C++ 2.0

You should reinstall after following the above steps.

5.8 Setup Frequently Asked Questions (FAQs)

5.8.1 After installing Visual C++ 5.0, I am getting an application error in MSDEV.EXE

Compiling a file in Developer Studio may cause the above error. The cause for this is that the install directory contains spaces and the root directory contains a file with the same name as the first part of the install directory. For example, if Developer Studio is installed in “C:\Program Files\DevStudio\” and there is a file in the root drive named as “C:\Program”. The resolution is to rename or delete the file or uninstall and reinstall Visual C++ in a directory without spaces in the name. The details are spelled out in KB article Q165792, "BUG: MSDEV.EXE Application Error When Building an Application."

5.8.2 Internet Explorer failed to install in Visual C++ 5.0 installation

During the installation of Visual C++ version 5.0, you may get an error message that Internet Explorer can not be installed. Do the following to resolve the issue.

  1. If Internet Explorer is already installed, uninstall from Control Panel’s Add/Remove programs.

  2. Install the latest version of Internet Explorer from the Microsoft Web site or from the MSDN Library.

After installing Internet Explorer, you can start the installation of Visual C++.

5.8.21 In Visual C++ 5.0, while doing a Help Search on a topic in the InfoViewer, you may encounter the following warning:
"Illegal operation, invalid page fault in deviv.pkg at 0137:5131400C"
   Or,
You get the message "merging keywords", then Developer Studio hangs and you may also get a "Out of memory" message.

  1. Increase virtual memory in Control Panel\System\Performance and make sure that there is about 20 MB of free space available in the corresponding hard drive partition.

  2. Delete the file named <number>.ivk, in the \Program File\Devstudio\SharedIde\Help directory where <number> is a decimal number. 

  3. Reboot the machine, select Help, and search on a topic in Developer Studio. Be patient—the process could take from 5 to 10 minutes. The *.ivk file is the keyword index for Help and is about 2 MB in size.

  4. If the above fails, you may have a faulty System Cache (also known as Internal and External Cache in some BIOS). In the BIOS setting, disable the System Cache (or Internal and External Cache). Delete the *.ivk file and try to access Help again.

If the above does not work, try a clean uninstall and then reinstall Visual C++ 5.0. Alternatively, you may have to try the hardware troubleshooting techniques described below.

5.8.22 Is it possible to install Internet Explorer in a directory of choice ?

Visual C++ 5.0 requires Internet Explorer to view the Online Help topics in Developer Studio and installs Internet Explorer if it is not already installed. When you start Visual C++ setup, Internet Explorer is automatically installed first in a default directory in the operating system's partition (for example, C:\Program Files\). If you want to install in a drive of your choice, and if you have already installed a version of Internet Explorer, you must uninstall this version of Internet Explorer by running Control Panel and selecting Add/Remove Programs. Then run the MSIE30.EXE file found in the IE30 directory of the Visual C++ CD (CD1 or CD3 in Visual Studio 97) before starting the Visual C++ setup. This will start Internet Explorer setup and you can select the installation directory. After completion of Internet Explorer installation, you can start the Visual C++ setup.

Note that although Visual C++ InfoViewer requires Internet Explorer to view the Online Help topics, you may choose a different browser as your default browser for browsing the Internet.

5.8.3 While starting Developer Studio for Visual C++ version 5.0, you may get the following error.
a) Syntax error mk:@ivt:vccore/F19/D1E/S38D2.HTM
b) Can not connect to Internet site at mk:@ivt:vccore/F19/D1E/S38D2.HTM

The above error message may refer to a different html file. To resolve the issue do the following.

  1. Run Visual C++ setup with the /F switch so that all the required DLLs are registered and the registry keys are properly recreated.

  2. If the above does not resolve the issue, reinstall Visual C++ 5.0 after proper uninstall.

5.8.4 While starting Developer Studio for Visual C++ version 5.0, you may get several error messages repeated in the following form with different titles.
"Title Registration error, unable to access Win95DDK, OK"
   Or,
"Error loading DEVDTG.PKG"

The above error message appears if the Beta version was installed before and it was not properly uninstalled. To resolve the issue, do the following.

  1. Delete the registry keys ...\InfoViewer\5.0 from HKEY_CURRENT_USER and HKEY_LOCAL_MACHINE. Then run Visual C++ setup with the /F switch.

  2. If the above does not resolve the issue, reinstall Visual C++ 5.0 after proper uninstall.

5.8.5  During installation of Visual C++ you may get an error message of the form "~VCB382 caused an invalid page fault in module ODBCCP32.DLL at 0137:04ab60ac."
   Or,
Unhandled exception in ~vc5.tmp(ODBCCP32.DLL): 0xc0000005: access violation, when the Cancel button is clicked at an error message "Copying Files: ~vc5.tmp - Application Error"

You may get the above error message during the installation while the ODBC components are being installed. To resolve this issue, do a Custom Install without the ODBC components (uncheck Database Options). You can install the ODBC components later by running setup.exe from the ...\DAOSDK\DISK1 directory, or the ...\DevStudio\Vc\Redist\DAO\DISK1 directory, or the ...\MSDEV\Redist\DAO directory.

If you are installing version 5.0, then you may try the Custom Install option and uncheck ActiveX Controls. Checking this button registers the OLE Controls for use in MFC applications. You can later copy these controls from the CD-ROM ...\Vc\Redist\OCX directory. Copy the control’s .ocx or .dll file and its .dep extension to the Windows System or System32 (for Windows NT) directory. Then register the control by running the REGSVR32.EXE on the .ocx or .dll file. You will then see this control included in the list of registered ActiveX Controls when you try to add components in your project.

If the above does not work, then you must have noticed that the error message shows up after 100 percent of file copying is complete. A work-around at this point is to install the ODBC components as mentioned above and run Visual C++ setup with the /F switch, or manually create the program icons. Manually creating the icons will not create the required registry entries for InfoViewer 5 to work properly. Creation of InfoViewer registry key is discussed in section 5.8.9.

The file ~vc5.tmp (the file may have a different number other than 5) is created as a temporary file by setup for storing setup-related information that is referred to at various stages of setup. A corruption in this file usually causes the above error. The corruption could be due to disk error or other file-system–related errors.

If none of the above works, then you should follow the general installation troubleshooting techniques discussed before.

5.8.6 While installing version 5.0, you may get the following error:
The ODBC resource DLL ( <Path to Windows SYSTEM directory>\ODBCINT.DLL) is a different version than the ODBC setup DLL ( <Path to Windows SYSTEM directory >\ODBCCP32.DLL). You need to reinstall the ODBC Components to ensure proper operation. Press OK to proceed, Cancel to abort.

If you press OK, installation will proceed to completion. The reason for this error is if during installation other programs are running and using the ODBCINT.DLL, the installation program may fail to copy the DLL from the CD-ROM. Copy the ODBCINT.DLL later from the CD-ROM ...\Vc\Redist\ directory to the Windows System (System32 in Windows NT) directory. The version number of the two DLLs is 03.00.2301. You may have to rename the existing DLL before copying and then delete the renamed DLL.

5.8.7 During installation of version 5.0 or MSDN, you may get the following error:
Setup error 168: Setup encountered an error updating your registry.

The above error may occur during MSDN installation if the registry key to be modified is being locked up or used by other applications. Subsequently, you may not be able to use MSDN. Try the following resolutions.

  1. Delete the registry keys ...\InfoViewer\5.0 from HKEY_CURRENT_USER and HKEY_LOCAL_MACHINE. Close all applications. Try installing MSDN again.

  2. Download RegCln41.exe from Microsoft ftp site (ftp.microsoft.com/Softlib/MSLFILES) and run it to clean the registry. Try Step 1 again.

  3. Open the Registry Editor. Open the Key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\SharedDLLs. Save this Key by highlighting it and selecting from Registry menu Export Registry File . . . . Save the file with a name (such as SaveKey) in a temporary directory (such as C:\TEMP). A file will be created with the name SaveKey.dat. Now delete the key. Try Step 1 again. After successful install, import the saved registry file by selecting Import Registry File . . . from the Registry menu and import the saved file C:\TEMP\SaveKey.dat. This will combine the old information and any new information created for that Key. Import the saved file even if the error does not resolve for the sake of restoring the original.

  4. See if KB article Q163277, "Setup Error 168 or Tahoma Font is Not Present Error," is applicable.

  5. Run MSDN setup from an MS-DOS command line as “setup.exe /gerrorlog.txt“, without the quotes and with no spaces between /g and errorlog.txt. The errorlog.txt file will contain information about when setup failed. Use that information to find the registry Key that caused the failure and apply Step 3 accordingly. The error-log file may give valuable information for troubleshooting.

5.8.8 You may get the following error while using Visual C++:
MSDEV.EXE - Application Error. The instruction at <Hex Address> referenced memory at  <Hex Address>. The memory could not be "read".
   Or,
MSDEV caused an invalid page fault in  <Module Name> at
<Hex Address>. Unhandled exception in MSDEV.EXE (<Module Name>) 0xC0000005: access violation

If you get the above error message, it could be due to a faulty installation or some software conflict. You need to follow the general installation troubleshooting techniques discussed above. The following is a partial list of resolutions found for this error.

5.8.9 I get the error message "Setup Cannot Execute the DDE Command Activate Progman", followed by Abort, Retry, Cancel.

Close all applications before starting the setup program. If setup is started from Explorer or an MS-DOS window, you can close them after the first setup screen is displayed. Continue with setup.

If you get the same error message as above, click on the Abort button and setup will continue to completion. At this point, setup has copied all the files (100 percent complete), but the program icons are not created. You can start Developer Studio from Explorer by double-clicking on the MSDEV.EXE file in the installed hard drive ...\BIN directory. All the components of Visual C++ will work properly. At this point you have the following choices.

Version 4.x

Use the following list of files to create the program icons, assuming the root directory is C:\.

  1. \MSDEV\BIN\MSDEV.EXE, icon name Microsoft Developer Studio.

  2. \MSDEV\BIN\TRACER.EXE, icon name MFC Tracer.

  3. \MFCKIT\DISK1\SETUP.EXE, icon name MFC Migration Kit setup from CD-ROM.

  4. \MSDEV\BIN\hcw.exe, icon name Help Workshop.

  5. \MSDEV\BIN\SPYXX.exe, icon name Spy++.

  6. \MSDEV\VCREAD.WRI, icon name Release Notes.

  7. \MSDEV\BIN\winnt\PVIEW.EXE, icon name Pview. Replace winnt by Win95 for Windows 95.

  8. \MSDEV\BIN\SETUPDBG.EXE, icon name NT System Symbols Setup. Not in Windows 95.

  9. \MSDEV\BIN\WINDIFF.EXE, icon name WinDiff.

  10. \MSDEV\BIN\VCREMOVE.EXE, icon name Uninstall Visual C++. Not in windows 95.

  11. \MSDEV\help\PSS.HLP, icon name Technical Support.

  12. \MSDEV\EEREADME.WRI, icon name Enterprise Edition release Notes (for Enterprise edition).

  13. The target for this icon is C:\WIN95\SYSTEM\REGWIZ.EXE /i “Software\Microsoft\Visual C++\4.0\Registration”. For Windows 95 only.

Items 7 and 9 are not available in the Standard version.

Version 5.0

Use the following list of files to create the program icons, assuming the install directory is C:\Program Files\DevStudio.

  1. \Program Files\DevStudio\VC\bin\TSTCON.EXE, icon name ActiveX Control Test Container.

  2. \Program Files\DevStudio\VC\bin\HCW.EXE, icon name Help Workshop.

  3. \Program Files\DevStudio\VC\bin\TRACER.EXE, icon name MFC Tracer.

  4. \Program Files\DevStudio\VC\bin\MSDEV.EXE, icon name Microsoft Visual C++ 5.0.

  5. \Program Files\DevStudio\VC\bin\OLEVIEW.EXE, icon name Object Viewer.

  6. \Program Files\DevStudio\VC\bin\win95\PVIEW95.EXE, icon name Process Viewer. It is winnt\PVIEW.EXE for Windows NT.

  7. \Program Files\DevStudio\VC\VCREADME.HTM, icon name Release Notes.

  8. \Program Files\DevStudio\VC\bin\SPYXX.EXE, icon name Spy++.

  9. \Program Files\DevStudio\VC\bin\WINDIFF.EXE, icon name WinDiff.

  10. \Program Files\DevStudio\SharedIDE\help\PSS.HLP, icon name Technical Support.

  11. \Program Files\DevStudio\SharedIDE\bin\SETUPDBG.EXE, icon name NT System Symbols Setup, available in Windows NT only.

  12. The target for this icon is C:\WIN95\SYSTEM\REGWIZ.EXE /i “Software\Microsoft\Visual C++\5.0\Registration”, icon name Register Visual C++. For Windows 95 only.

5.8.10 Is it possible to install the Document/Help files in a network shared directory ?

The following sections for each version contain the answer to the above question.

Version 4.x

After installing Visual C++, create a directory named MSDEV in the network share, for example, \\ShareNetwork\MSDEV, where \\ShareNetwork is the address of the network drive to which you want to copy the Help files. Now copy from the CD-ROM the MSDEV\HELP directory and the MSDEV\SAMPLES directory to the MSDEV directory in the network share.

The following are the registry keys associated for viewing the documents. Start the registry editor by running REGEDIT.EXE in the Windows directory or REGEDIT32.EXE from the SYSTEM32 directory.

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\DocSets\MSDEV40\MSDEV40.MVB\(Default)\(value not set)
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\DocSets\VCAPP40\VCAPP40.MVB\(Default)\(value not set)
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\DocSets\VCBKS40\VCBKS40.MVB\(Default)\(value not set)
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Series\VCBOOKS\(Default)\(value not set)
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Series\VCBOOKS\Release\”3”
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Series\VCBOOKS\Title\”VCBKS40MVB”

If you installed version 4.2, then you will see the following entries also under “Series”.
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Series\ACTIVEX\(Default)\(value not set)
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Series\ACTIVEX\Title\”ACTIVEXMVB”

If you installed the Standard version, then you will see the following entries also under “Series”.
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Series\INSIDE3\(Default)\(value not set)
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Series\INSIDE3\Release\”1”
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Series\INSIDE3\Title\”INSIDE3MVB”

The following registry key values are shown assuming that the installation directory is C:\MSDEV and CD-ROM drive is E:\. If you have installed the Standard version, the installed (default) directory is C:\MSDEVSTD.

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Titles\MSDEV40.MVB\(Default)\(value not set)
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Titles\MSDEV40.MVB\LocalDir\”C:\MSDEV\HELP”
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Titles\MSDEV40.MVB\Path\”C:\MSDEV\HELP”
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Titles\VCAPP40.MVB\(Default)\(value not set)
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Titles\VCAPP40.MVB\LocalDir\”C:\MSDEV\HELP”
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Titles\VCAPP40.MVB\Path\”C:\MSDEV\HELP”
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Titles\VCBOOKS40.MVB\(Default)\(value not set)
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Titles\VCBOOKS40.MVB\Exe\”C:\MSDEV\BIN\msdev.exe”
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Titles\VCBOOKS40.MVB\LocalDir\”C:\MSDEV\HELP”
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Titles\VCBOOKS40.MVB\Path\”E:\MSDEV\HELP”
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Titles\VCBOOKS40.MVB\SampleCD0\”E:\MSDEV\”
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Titles\VCBOOKS40.MVB\SamplePath\”C:\MSDEV\”
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Titles\VCBOOKS40.MVB\Series\”VCBOOKS”
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Titles\VCBOOKS40.MVB\Title\”Visual C++ Books Online”

You now need to change the E:\ drive to the network share name for the Path and SampleCD0 key values shown above, for example, change to \\ShareNetwork\MSDEV\HELP and \\ShareNetwork\MSDEV for Path and SampleCD0 respectively. Likewise, change the Path values for the following two keys to \\ShareNetwork\MSDEV\HELP as shown. To change the values, double-click on Path or SampleCD0 and you will get an edit box for making the change. There are no SampleCD0 and SamplePath values for the ACTIVEX.MVB and INSIDE3.MVB keys; the rest of the values are identical to that of VCBOOKS40.MVB.

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Titles\INSIDE3.MVB\Path\”\\ShareNetwork\MSDEV\HELP”

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Titles\ACTIVEX.MVB\Path\”\\ShareNetwork\MSDEV\HELP”

There is an identical key in HKEY_CURRENT_USER for InfoViewer. Delete this key. Start Developer Studio; you will find that this key is automatically created and you are accessing the documents from the network share.

Version 5.0

The Visual C++ version 5.0 box contains the MSDN CD. Copy the entire CD image to a network drive. Run the MSDN setup from this network share. All the registry keys will be properly created to run from this network share. You can then delete the subdirectories ...\Ie, ...\Acme, and ...\System.

You will find the following registry entries pointing to the MSDN directory in the network share:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\5.0\Locations\MSDNCD19d1\Path
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\5.0\Locations\MSVC50\Path

And the Content entry of the <titlename> (for example, activex. ) registry entry shown below will point to the corresponding IVT (for example, activex.ivt) file of the <titlename> in the MSDN directory in the network share. The Index entry will point to the IVI file of <titlename> located in the hard drive installed directory of MSDN (for example, ...\DevStudio\MSDN\activex.ivi ).

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\5.0\Titles\<titlename>

Version 2.x

Change the following registry key to point to the network share directory after copying the HELP directory from the CD-ROM to the network share.

HKEY_CURRENT_USER\SOFTWARE\Microsoft\Visual C++ 2.0\Help\RemoteHelp1\”E:\HELP”

5.8.11 I do not see any InfoViewer titles and cannot access any documents or help titles.

First try running setup.exe for Visual C++ with the /f switch. This should create all the required registry keys. Otherwise, try the following resolutions for each version. To create a new sub key, highlight the key and from Edit menu select Key\New, and then type the name of the new key in the edit box created. To assign a value to the new sub key, do likewise but select Edit Key\(Type)Value, where Type could be String, Binary, or DWORD. Select a name for the value field, double-click on this name and assign the required value.

Version 4.x

Check that all the registry keys mentioned in section 5.8.8 exist. If not, create the registry keys. The minimum required are the following keys with their corresponding values shown in section 5.8.8.

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Series\
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\Titles\

Version 5.0

The most important registry keys for the InfoViewer topics to show in Developer Studio are listed below. Make sure that these keys exist.

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\5.0\Folders\
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\InfoViewer\5.0\Titles\

The number of sub keys and values under the above two keys are too many to be created manually. Check for any unusual entries in these keys, such as not pointing to the right directory. Under Folders you should see Developer Products, Microsoft Developer Network Visual Studio Edition, Platform, SDK, and DDK Documentation, Tools and Technologies. Again under Developer Products you should see Visual C++, which will have entries like =dshelp\Order\”g”, etc. Likewise for the other topics. Under Titles you should see entries like 3dgraph, etc., which in turn will have several entries, Content, Index, Location, where Content points to the corresponding IVT file (for example, activex.ivt) location, usually your CD-ROM drive path to the corresponding MSDN sub directory containing the IVT file. Index will point to the corresponding IVI file(for example, activex.ivi) in the installed hard drive directory (for example, ...\DevStudio\MSDN\activex.ivi ).

Therefore, instead of trying to create manually all the entries, it is advisable that you delete the ...\InfoViewer\5.0 key and try reinstalling MSDN after uninstalling it from Add/Remove programs in Control Panel.

Version 2.x

Check that you have the following registry keys. If you don't have them, create them with the values shown.

HKEY_CURRENT_USER\SOFTWARE\Microsoft\Visual C++ 2.0\Help\RemoteHelp1\”E:\HELP”
HKEY_CURRENT_USER\SOFTWARE\Microsoft\Visual C++ 2.0\Contents\Current Bookset\“Books Online”
HKEY_CURRENT_USER\SOFTWARE\Microsoft\Visual C++ 2.0\Contents\Current Bookset\FTS Files\ vc20bks1.hlp vc20bks2.hlp vc20bks3.hlp vc20bks4.hlp vc20bks5.hlp vc20bks6.hlp vc20bks7.hlp

5.8.12 How do I change the keyboard settings back to Developer Studio?

During setup of Visual C++ versions 4.x and 5.0, setup gives the option to choose your keyboard settings to “Developer Studio” or “Visual C++ 2.0”. If you have chosen “Visual C++ 2.0” then you may change it back to the “Developer Studio” keyboard setting without reinstalling Visual C++.

In Developer Studio, choose Options from the Tools menu, then select the tab Compatibility. Select Developer Studio from the Current source editor emulation list box, and press OK. For more information, see the KB article Q139271, "BUG: Changing Keyboard Compatibility Fails to Update Some Keys."

5.8.13 I am getting Error C1001 Internal Compiler error while building my project.

This error may be encountered during the testing phase of installation or later.

A C1001 error may occur due to a known bug in the compiler, a new bug in the compiler, a missing right curly brace in a source file, a file corruption problem, a hardware problem in the machine, or it may only happen (randomly) for a large project in a (Novell) network. The error may appear during compilation of the very first file during a Build in the IDE, or always during compilation of a particular file, or randomly during compilation of any files in the project. The error message may contain the filename of the project with a line number in parenthesis, or without any project file name. The two variations are shown below. Note that the compiler file name corresponds to the original source file of the compiler, which may be different for each of the C1001 errors.

C:\code\Myproject\Test.cpp(20) : fatal error C1001: INTERNAL COMPILER ERROR (compiler file 'msc1.cpp', line 1089) Please choose the Technical Support command on the Visual C++ Help menu, or open the Technical Support help file for more information.

   Or,

fatal error C1001: INTERNAL COMPILER ERROR (compiler file '@(#)main.c:1.82', line 289) Please choose the Technical Support command on the Visual C++ Help menu, or open the Technical Support help file for more information.

If the error message is of the first type, you should try to compile only this file from the IDE or from the command line using the “CL /c Test.cpp” command (without the quotes). If the error is repeated, see if it is a known bug by searching the KB articles for error message C1001. If no KB articles relate to the line number 20 syntax, and commenting out the line does not generate the error message, you may have found a new bug. You may report new bugs at Microsoft Web address http://www.microsoft.com/VisualCSupport/report/ or call Microsoft Technical Support for help in working around the bug.

The second error message does not have a filename or may list a bogus file name. Check the following.

  1. Create a simple one-line program printing “Hello world”. Try to compile this file from the IDE or from the command line.

  2. Try to build a default Appwizard-created project.

  3. The error may show up only for this project (probably a very large project).

  4. If the project is in a network share, see whether the problem goes away if moved to local hard drive.

Failure in items 1 and 2 means an installation problem related to software or hardware. In most cases it turns out to be hardware related. Try first uninstalling and reinstalling the product, or else try the general setup troubleshooting technique described above. Most probably the hardware troubleshooting technique will resolve the issue.

For item 3 above, try the steps in the previous paragraph. You can also try to determine if it can be reproduced in another machine. In that case, it could be due to a limitation in the compiler, which can be verified by reducing the number of files in the project or the size of large files.

Success in item 4 above means the problem has to be resolved from the network side. A good test is to see if it can be reproduced in other computers in the network.

5.8.14 The classes in my project do not show up in ClassView.

If you are unable to see classes in ClassView for your project, then it is very likely that your project’s .ncb and .clw files might be corrupted. Close your project workspace, then delete these two files from your project. When you open your project again, you should be able to see the classes in ClassView.

If the above does not resolve the issue, create a source file with a simple class and save it as testclass.cpp. Add this file to a new Console project. Check to see whether you can view the class and its members in ClassView. If not, then check if your machine has an Award BIOS version 4.50PG. If yes, then you need to use a later version, for example AWARD BIOS version 4.51. Reinstall Visual C++ after uninstall to resolve the issue. It is to be noted that if you now go back to your old BIOS, the problem will not reappear.

Make sure that no error was reported during installation of Visual C++. Try to get an error-free installation following the general installation troubleshooting techniques discussed before.

5.8.15 I am getting repeated blank screens during the build process.

Try the resolution given in KB article Q126031, "Repeated Blank Screens During Build Process in VC++ 2.x." This is applicable to all the 32-bit versions of Visual C++.

5.8.16 I find that after exiting Visual C++, I can see it in Pview, and I can not restart Visual C++. It seems some threads are still running or it is not releasing memory back to the operating system.

The reason for this behavior could be due to the description given in KB article Q153324, "BUG: MSDEV May Leave Orphaned Threads in the Memory AfterExit."

5.8.17 During installation of Visual C++, you may get the error message "Setup cannot write to the Registry".

The above error may show up when the setup program tries to write to the AeDebug section of the \WINDOWS95\WIN.INI file, and the registry key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\Current Version\AeDebug.

For Windows 95, read “Windows NT” as “Windows”. Deleting the AeDebug key and running setup again with the /f key will resolve the above error. If you are using Windows 95, it may also be necessary to comment out the two lines (starting with Auto and Debugger) in the AeDebug section in the win.ini file before running setup.exe with the /f switch.

5.8.18 During installation of Visual C++, when file copying starts I get a blue screen and have to reboot my machine.

If you find that this is happening about midway during the file copying process, instead of trying the general troubleshooting process right away, see if you can read the name of the file when this happens. Copy this file manually using the COPY command from the CD-ROM and restart setup. Since the setup program does not copy the file already existing in the hard drive, you may pass the problem point and complete a successful installation.

5.8.19 When I press F1 (to get online Help) on a linker or a compiler error in the Build Output Window, the machine reboots.
   Or,
The machine randomly hangs or generates an Exception error in MSDEV.EXE when I scroll the text on the online help text.
   Or,
The machine randomly hangs or generates an Exception error in MSDEV.EXE when I switch to or from the Debugger.

This problem may occur due to hardware conflict in the video display. Change video color resolution to a lower value. If it is set at 24 bit (true color) or 1,677,7216 colors, try 16-bit (65,536 colors ) or 256 colors. If it is set at 16-bit, try 256 colors. Try one lower step at a time.

To set the color resolution, go to Display from Control Panel and select the Settings tab, and drop down the Color Palette list box.

If this resolves the issue, you may contact the Video card vendor or check their Internet Web site for any available newer driver for the card or any other related information.

5.8.20 Trying Online registration, you may get an error "This task could not be completed."
   Or,
“BILLADD.DLL is linked to missing export MCM.DLL”

The above errors may be ignored and you can continue with setup. Setup will complete successfully. You can then send the Registration card in the box by U.S. Mail. Online Registration errors can be ignored to continue with setup.

The first error may be due to incompatible settings in the modem. You may try the following articles for a resolution. The second error may be due to corrupted DLLs in Windows 95. See KB articles Q153473, "Extra Modem Settings for Connection Problems" and Q149332, "Problems Connecting to MSN with U.S. Robotics Sportster Modem."

6.0 Network Installation

Installing all or any part of a Microsoft language compiler on a network is permitted only if each person that intends to use the product has a license to use the product. For more information in this regard, see KB article Q34445, "Installing Language Products on a Network."

It is to be noted that Visual C++ is not designed for network installation. The following are suggestions only.

6.1 16-bit Version

The KB Article Q97672, "Running the Visual Workbench from a Network Drive" describes a work-around for network installation.

6.2 32-bit Version

To install the 32-bit versions of Visual C++ in a network drive, copy the whole CD image into a network server directory. From each workstation, connect to the network share and run setup.exe from the CD image. Select CD-ROM install when setup asks you to select the type of installation. About 40 MB of disk space will be used in the workstation for the CD-ROM installation, including the system DLLs needed to run Visual C++. Most of the utilities will be run from the network server. The workstation will run its own copy of the IDE, using the network only when necessary.

7.0 Hardware Troubleshooting

If you have reached this section, it is assumed that you have already tried uninstalling and reinstalling Visual C++ and the problem did not get resolved. If the source of the problem remains undetected after following the steps discussed in this section, then you need to uninstall Visual C++, reinstall the operating system and/or apply the latest service pack and hope that the Visual C++ installation problem gets resolved.

Visual C++ uses system resources very heavily compared to other applications. Therefore, hardware problems may show up during installation and use of Visual C++. The following is a list of possible hardware problems.

For each of the problems listed above, the following suggestions may be applied for resolution.

7.1 Visual C++ CD-ROM Disk Is Defective

Check to see if there is dust or scratch marks on the Visual C++ CD. Clean the CD with a soft damp cloth, let it dry, and try again. If another computer is available, try to install Visual C++ on it. A successful install will indicate a defective CD-ROM drive, whereas an unsuccessful install will indicate a defective CD.

A successful install will indicate a defective CD-ROM drive.

7.2 Defective Internal/External Cache Memory on Motherboard

There is a possibility that the internal or the external cache has defects not detected before. Presence of such defects can be verified by disabling the internal and external cache from the BIOS setting. You may disable selectively one or both at the same time (some BIOS refer to it as system cache). From the BIOS settings, disable the cache (internal, external, or system), and try again to resolve the issue. If you succeed, you found the problem. This may mean changing the external cache memory chips or the CPU.

How do I change the BIOS settings ?

Depending on the type of BIOS in your computer, during the boot process messages will appear on the boot screen starting with the manufacturer’s name, version number, etc. You will also see a message, like, “Hit the <KEY> to change settings”, where the <KEY> could be the DEL or the F1 key or some other key. When you hit the <KEY>, you will get the BIOS menu screen. Again depending on the type and version of the BIOS, the menu screen may be different. Some are easy to navigate, others not so obvious. Given below are three examples so that you get an idea of how to navigate; otherwise, you need to call the BIOS manufacturer or the computer manufacturer. (Some Dell computers need a separate diskette to change the settings.)

BIOS example 1: AMI BIOS 1993, UCV-G

The menu screen has several items. One of them is “Advanced CMOS setup”. Select this menu item and press Enter. You will find the item “External Cache”, which may be disabled by selecting the item and using the “Page Down“ key. Follow the instructions to save the changes and exit from the BIOS settings environment.

BIOS example 2: AMI BIOS 1992, version 1.00.00

In the display screen, you will find a menu item “Main”. Select “Main” using the left/right arrow keys, select the item “Boot Options” using the up/down arrow keys, and then press Enter. You will find the item “System Cache”, which can be disabled by selecting and pressing Enter. Follow the instruction to save the changes and exit from the BIOS settings environment.

BIOS example 3: Phoenix BIOS, version 4.03

From the “Main Menu”, select the item “Advanced System Setup” and press Enter. This will bring up another menu. Select the item “Advanced Chipset Control” with the down-arrow key and press Enter. You will find the item “External Cache”, which may be disabled by selecting the item and using the “Page Down“ key. Follow the instructions to save the changes and exit from the BIOS settings environment.

7.3 Flaky CPU or Defective Cooling Fan

A defective cooling fan on the CPU may overheat the CPU, leading to unpredictable behavior. Check the fan to see if it is working properly. Sometimes, the CPU itself may be erratic in its operation or the system motherboard has not been properly tested to work in the specified CPU clock frequency. The CPU speed can be changed in some BIOS to Turbo/DeTurbo or High/Low. As shown in the BIOS examples above, you may select DeTurbo or Low for the CPU to work at a lower speed. Some computers contain a Turbo OFF/ON switch in the front panel; you may try this switch instead of changing the BIOS settings. If a spare CPU or a spare system motherboard is available, you may try that too.

7.4 Defective RAM Chip on Motherboard

The RAM chip in the motherboard may be defective, or sometimes enabling parity check in the BIOS setting can be a cause of trouble (particularly if parity and nonparity memory SIMMS are mixed). You may disable parity check in memory in the BIOS setting following the BIOS example shown above.

Visual C++ version 4.x will work in Windows 95 with 8 MB RAM (though 16 MB is recommended), and Windows NT needs a minimum of 20 MB of RAM. If your system has more memory, you can pull out RAM chips to the minimum required and try various combinations swapping with the memory pulled out. If you have another spare motherboard available, you may try that too.

7.5 A Defective CD-ROM Drive or Controller

A defective CD-ROM drive or controller is uncommon, but cannot be ruled out as a possibility. Before you try to get hold of another CD-ROM drive or controller card, and if you are using Windows 95, you may try the following to see if the problem will go away.

  1. Click the Start button, point to Settings, then click Control Panel.

  2. Double-click the System icon.

  3. On the Performance tab, click File System.

  4. Click the CD-ROM tab.

  5. In the Optimize Access Pattern For box, click the setting that matches the CD-ROM drive you are using. Click OK. Restart the computer when you are prompted to.

  6. If steps 1–5 do not solve the problem, repeat steps 1–4. In the Optimize Access Pattern For box, click No Read Ahead. Click OK. Restart the computer when you are prompted to.

If you need more information, consult KB articles Q132882, "Computer Hangs Copying Data from CD-ROM Drive" and Q126380, "Troubleshooting CD-ROM Problems in Windows NT."

7.6 A Defective Hard Disk Drive or Controller

Again, it is very uncommon to have a defective hard disk drive or controller. Try CHKDSK or SCANDISK and DEFRAG (if available) on the drive before trying to find another hard disk drive or controller. SCSI hard drives show erratic behavior if the drive is not terminated properly. Your hard drive manual will contain proper termination information. For more information, consult KB articles Q133285, "SCSI Setup & Basic SCSI Troubleshooting in Windows 95" and Q101352, "Properly Connecting SCSI Devices to Windows NT."

If you are using Windows 95, you may try with a different configuration (for example, “Basic Configuration 1” instead of “Basic Configuration 0”, or vice-versa). Before trying this, it may be advisable that you create a Hardware Profile as discussed in KB article Q134347, so that you have the provision of rebooting in your original configuration in case you run into trouble. Now, to change to a different basic configuration for your hard drive controller, from Control Panel, go to System Properties\Device Manager\Hard disk controllers, then double-click on the corresponding listed Hard Disk Controller. In the General Properties tab, select Current Configuration, then select the Resources tab. Click on Set Configuration Manually. Uncheck Use automatic settings, then select Basic Configuration 1 or Basic Configuration 0 from the drop-down box, and then check again the Use automatic settings box. You will be advised to reboot the machine. Select the configuration for which you made the changes when you get a reboot response. If this works for you, you can make the changes to your original configuration and delete the saved configuration so that you are not asked to select a configuration every time you reboot. For more information on changing device configuration, you may consult KB article Q133240, "Troubleshooting Device Conflicts with Device Manager."

7.7 A Defective or Incompatible Video Card

Make sure that the jumper settings for video memory speed and RAM speed match. For example, if RAM is of 60 nanosecond access time, set the video card jumpers to the same speed setting.

Changing the video colors to 256 may also resolve the issue. Even if you tried the VGA mode, the card itself may be defective or incompatible. Changing to a generic video card or a different video card model from the same manufacturer may also resolve the issue. If Windows 95 or Windows NT automatically finds the driver for the card, it is better. Otherwise, you may try different drivers on a trial-and-error basis from the list of drivers of the same manufacturer as shown available in Windows 95 and Windows NT. Windows NT 4.0 may have some problem with the ATI video driver. You may find additional information in the Windows NT 4.0 Readme.wri file. Also, see KB article Q157543, "PRB: Bitmap Editor Distorts Icons and Bitmaps."

8.0 Conclusion

This article discusses setup issues related to installation of the 16-bit and the 32-bit versions of Visual C++. The installation problems one encounters fall under the categories of software conflicts or hardware problems. All possible scenarios of such conflicts or problems are considered. Of course, there will always be new ones. Nevertheless, the article describes all the troubleshooting techniques necessary for resolving any unknown issues. The list of frequently asked questions in section 5.8 will help you find a quick resolution.