Table of contents
TOC
Collapse the table of content
Expand the table of content

Trappable Errors

office 365 dev account|Last Updated: 6/12/2017
|
1 Contributor

Trappable errors can occur while an application is running. Some trappable errors can also occur during development or compile time. You can test and respond to trappable errors using the On Error statement and the Err object. Unusederror numbers in the range 1 - 1000 are reserved for future use by Visual Basic.

CodeMessage
3Return without GoSub
5Invalid procedure call
6Overflow
7Out of memory
9Subscript out of range
10This array is fixed or temporarily locked
11Division by zero
13Type mismatch
14Out of string space
16Expression too complex
17Can't perform requested operation
18User interrupt occurred
20Resume without error
28Out of stack space
35Sub, Function, or Property not defined
47Too many code resource or DLL application clients
48Error in loading code resource or DLL
49Bad code resource or DLL calling convention
51Internal error
52Bad file name or number
53File not found
54Bad file mode
55File already open
57Device I/O error
58File already exists
59Bad record length
61Disk full
62Input past end of file
63Bad record number
67Too many files
68Device unavailable
70Permission denied
71Disk not ready
74Can't rename with different drive
75Path/File access error
76Path not found
91Object variable or With block variable not set
92For loop not initialized
93Invalid pattern string
94Invalid use of Null
97Can't call Friend procedure on an object that is not an instance of the defining class
98A property or method call cannot include a reference to a private object, either as an argument or as a return value
298System resource or DLL could not be loaded
320Can't use character device names in specified file names
321Invalid file format
322Can't create necessary temporary file
325Invalid format in resource file
327Data value named not found
328Illegal parameter; can't write arrays
335Could not access system registry
336Component not correctly registered
337Component not found
338Component did not run correctly
360Object already loaded
361Can't load or unload this object
363Control specified not found
364Object was unloaded
365Unable to unload within this context
368The specified file is out of date. This program requires a later version
371The specified object can't be used as an owner form for Show
380Invalid property value
381Invalid property-array index
382Property Set can't be executed at run time
383Property Set can't be used with a read-only property
385Need property-array index
387Property Set not permitted
393Property Get can't be executed at run time
394Property Get can't be executed on write-only property
400Form already displayed; can't show modally
402Code must close topmost modal form first
419Permission to use object denied
422Property not found
423Property or method not found
424Object required
425Invalid object use
429Component can't create object or return reference to this object
430Class doesn't support Automation
432File name or class name not found during Automation operation
438Object doesn't support this property or method
440Automation error
442Connection to type library or object library for remote process has been lost
443Automation object doesn't have a default value
445Object doesn't support this action
446Object doesn't support named arguments
447Object doesn't support current locale setting
448Named argument not found
449Argument not optional or invalid property assignment
450Wrong number of arguments or invalid property assignment
451Object not a collection
452Invalid ordinal
453Specified code resource not found
454Code resource not found
455Code resource lock error
457This key is already associated with an element of this collection
458Variable uses a type not supported in Visual Basic
459This component doesn't support the set of events
460Invalid Clipboard format
461Method or data member not found
462The remote server machine does not exist or is unavailable
463Class not registered on local machine
480Can't create AutoRedraw image
481Invalid picture
482Printer error
483Printer driver does not support specified property
484Problem getting printer information from the system. Make sure the printer is set up correctly
485Invalid picture type
486Can't print form image to this type of printer
520Can't empty Clipboard
521Can't open Clipboard
735Can't save file to TEMP directory
744Search text not found
746Replacements too long
31001Out of memory
31004No object
31018Class is not set
31027Unable to activate object
31032Unable to create embedded object
31036Error saving to file
31037Error loading from file
© 2018 Microsoft