Word 97 Crashes

J

Jason

Word 97 is crashing on my system (Win 2k Pro SP2), but it is not crashing
others using the same system, Win 2k XP Pro, or Office 2003. This occurs
with a specific file, when attempting to print. Within this file, I have a
VBA procedure that intercepts the FilePrint and FilePrintDefault events, as
follows:

Sub FilePrint()
'
' FilePrint Macro
' Prints the active document
'
If ThisDocument.ProtectionType = wdAllowOnlyFormFields Then _
ThisDocument.Unprotect

Call HideCommandButtons

Dialogs(wdDialogFilePrint).Show

Call UnhideCommandButtons

ThisDocument.Protect wdAllowOnlyFormFields, True

End Sub

Sub FilePrintDefault()
'
' FilePrintDefault Macro
' Prints the active document using the current defaults
'
If ThisDocument.ProtectionType = wdAllowOnlyFormFields Then _
ThisDocument.Unprotect

Call HideCommandButtons

ThisDocument.PrintOut

Call UnhideCommandButtons

ThisDocument.Protect wdAllowOnlyFormFields, True

End Sub

Sub HideCommandButtons()

'hides command buttons and text box for printing
With ThisDocument.cmdCustomize
.Height = 0
.Width = 0
End With

With ThisDocument.cmdLetterhead
.Height = 0
.Width = 0
End With

ThisDocument.Shapes("Text Box 5").Visible = msoFalse

End Sub

Sub UnhideCommandButtons()

'unhides command buttons and text box
With ThisDocument.cmdCustomize
.Height = 23
.Width = 107
End With

With ThisDocument.cmdLetterhead
.Height = 23
.Width = 84.75
End With

ThisDocument.Shapes("Text Box 5").Visible = msoTrue

End Sub

Also, here is an excerpt from my DrWatson log for the most recent crash:

Application exception occurred:
App: WinWord.exe (pid=2196)
When: 7/31/2007 @ 13:17:16.037
Exception number: c0000005 (access violation)

*----> System Information <----*
Computer Name: xxxxx
User Name: xxxxx
Number of Processors: 1
Processor Type: x86 Family 6 Model 13 Stepping 6
Windows 2000 Version: 5.0
Current Build: 2195
Service Pack: 4
Current Type: Uniprocessor Free
Registered Organization: xxxxx
Registered Owner: xxxxx

*----> Task List <----*
0 Idle.exe
8 System.exe
184 SMSS.exe
212 CSRSS.exe
208 WINLOGON.exe
264 SERVICES.exe
276 LSASS.exe
392 ati2evxx.exe
464 svchost.exe
492 ccSetMgr.exe
532 ccEvtMgr.exe
612 SPBBCSvc.exe
648 spoolsv.exe
752 AeXNSAgent.exe
776 DefWatch.exe
796 DWRCS.exe
828 DISrv.exe
844 svchost.exe
936 hidserv.exe
972 Tuner.exe
1036 PCGProt.exe
1060 regsvc.exe
1048 SavRoam.exe
1108 scardsvr.exe
1128 mstask.exe
1212 Rtvscan.exe
1288 cclientsvc.exe
1304 WebClientSrv.ex.exe
1312 cclient.exe
1340 WinMgmt.exe
1360 svchost.exe
1864 ati2evxx.exe
988 explorer.exe
1972 DWRCST.exe
1800 prpcui.exe
1748 atiptaxx.exe
1328 CreateCD50.exe
1988 Directcd.exe
1944 LaunchEPHD.exe
2176 ccApp.exe
1888 VPTray.exe
2028 GoogleToolbarNo.exe
764 TSUsage32.exe
1412 NTVDM.exe
2236 FINDFAST.exe
2196 winword.exe
2484 DRWTSN32.exe
0 _Total.exe

Any ideas? TIA

Jason
 
S

Stefan Blom

Since this is potentially VBA-related, you may want to ask in a programming
newsgroup.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top