BUG: Incorrect SS==DS in DLL Makefile for Sample MUSCROLL

ID: Q117792

1.00 1.50 WINDOWS kbtool kbbuglist

The information in this article applies to:

SYMPTOMS

While running the sample MUSCROLL in the directory \MSVC\SAMPLES\MUSCROLL, one of the spin boxes is displayed as a black box.

Also, sometimes the DLL implementing the spin box generates a general protection fault (GPF).

CAUSE

The makefile MUSCROLL.MAK incorrectly sets SS == DS for the DLL.

RESOLUTION

Change the DLL setting from "SS == DS" to "SS != DS". This can be easily done in the Visual Workbench by using the following steps:

1. Open the project file MUSCROLL.MAK.

2. From the Visual Workbench menu bar, choose Project from the Options

   menu.

3. Choose the Compiler command button in the Project Options dialog box.

4. In the C/C++ Compiler Options dialog box, choose Memory Model in the

   category list box.

5. In the Segment Setup, next to the model selection, choose "SS != DS, DS
   NOT loaded on function entry". This forces the compiler to use option
   /AMw instead of /AM.

6. Choose the "OK" button.

7. In the Project Options dialog box, choose the "OK" button again.

8. Rebuild the DLL, using the new makefile.

9. Use a text editor to change the makefile. Use switch /AMw instead of /AM

   in the makefile for MUSCROLL.

The changes need to be done for both the debug build and the release build.

STATUS

Microsoft has confirmed this to be a bug in the Microsoft C/C++ Compiler for MS-DOS, versions 8.0 and 8.0c. We are researching this problem and will post new information here in the Microsoft Knowledge Base as it becomes available.

MORE INFORMATION

MUSCROLL is a product sample included in Microsoft Visual C++, versions 1.0 and 1.5. MUSCROLL is essentially a scroll bar without a thumb or thumbtrack and can be much smaller than a standard scroll bar. The control itself is implemented in a DLL called from the MUTEST application, which resides in the same directory as the DLL.

Additional reference words: 1.00 1.50 SS==DS KBCategory: kbtool kbbuglist KBSubcategory: CodeSam Keywords : kb16bitonly

Last Reviewed: July 23, 1997