Bug: Run-time error 91 occurs after exiting ArcMap
When exiting ArcMap, the following error displays:
Run-time error '91'
Object variable or With block variable not set.
Runtime error '440': Automation error."
This is a known issue.
This issue is addressed in PLTS 9.1 Foundation Service Pack 3 (SP3). See the link in the Related Information section below.