Microsoft KB Archive/141876

= Word 7 Calendar Wizard Creates One Month Only =

Article ID: 141876

Article Last Modified on 8/17/2005

-

APPLIES TO


 * Microsoft Word 95 Standard Edition
 * Microsoft Word 95a

-



This article was previously published under Q141876



SYMPTOMS
The Calendar Wizard creates only the starting month specified in the wizard, instead of creating a calendar for a whole year.



CAUSE
One of the instructions in the Wizard is implemented incorrectly. Specifically, the variable specified for the MaxValidYear in the wizard is not a shared variable.



WORKAROUND
WARNING: ANY USE BY YOU OF THE CODE PROVIDED IN THIS ARTICLE IS AT YOUR OWN RISK. Microsoft provides this macro code "as is" without warranty of any kind, either express or implied, including but not limited to the implied warranties of merchantability and/or fitness for a particular purpose.

The Calendar Wizard has a variable called MaxValidYear which is not shared, causing the Calendar Wizard to complete incorrectly when the Starting Year and Ending Years are different. The MaxValidYear variable needs to be a shared variable.

To change the MaxValidYear to a shared variable, perform the following steps:
 * 1) Click New on the File menu.
 * 2) Select the Calendar Wizard from the "Other Documents" tab. (Do not double-click the Calendar Wizard icon.)
 * 3) Press and hold the SHIFT key, then click OK. Keep the Shift key pressed down until a new blank document appears on the screen.
 * 4) Select Macro from the Tools menu.
 * 5) Select the StartWizard macro and click Edit.
 * 6) Find the "Dim MaxValidYear" statement. It should be the 10th DIM statement at the top of the wizard.
 * 7) Change the "Dim MaxValidYear" statement to read "Dim Shared MaxValidYear".
 * 8) Click Save on the File menu.
 * 9) Click Close on the File menu. If prompted to save the StartWizard macro, choose Yes.



STATUS
Microsoft has confirmed this to be a problem in the Word versions listed above. This problem was corrected in Microsoft Word 97 for Windows.



MORE INFORMATION
This behavior of the Calendar Wizard does NOT occur with any previous version of Microsoft Word for Windows, Microsoft Word for Macintosh, or Microsoft Word for Windows NT.

Additional query words: word95 word7 7.0 winword

Keywords: KB141876

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.