Macro Generates WordBasic Err=509, then GP Fault in SDM.DLL

ID: Q122554

The information in this article applies to:

SYMPTOMS

If you run the following WordBasic macro, which opens the Format Style dialog box, "WordBasic Err=509" may occur, followed by a general protection (GP) fault in module SDM.DLL:

Sub main
 Dim dlg As FormatStyle
 Dialog dlg
 FormatStyle dlg
End Sub

After the GP fault occurs, Word for Windows closes.

These errors do not occur if you choose Style from the Format menu.

CAUSE

The errors occur if after you run the above macro to open the Format Style dialog box, you do all of the following:

1. Choose the Modify button.

2. Choose the Format button.

3. From the Format list, choose Numbering.

STATUS

Microsoft has confirmed this to be a problem in Word for Windows versions 6.0, 6.0a, and 6.0c. This problem was corrected in Word version 7.0 for Windows 95.

WORKAROUND

Do not use the sequence of steps outlined in the Cause section above. If you choose a step other than Numbering, you will avoid the errors.

KBCategory: kbenv KBSubcategory: kbmacro Additional reference words: 6.0 6.0a 6.0c winword wordbasic err word6 509 GPF macro

Keywords          : kbmacro kbenv
Version           : 6.0 6.0a 6.0c
Platform          : WINDOWS

Last Reviewed: August 5, 1997