I haven’t found a good reference as to what the different TextOutputStream IOException error numbers mean. I don’t get an IOException Message (blank) and the IOException Error is “3”.
I know ‘why’ it’s throwing an exception (IT dept moved the mapping of a drive letter), but I’m wanting to better understand how to read the errors so I can make some specific error handling.
Anyone know if there’s a list of common I/O error #'s, and if “3” means anything specific?
From the Notes section on the IOException Documentation page:
The IOException represents errors that can occur while using the shared methods for opening and creating strea
ms: BinaryStream, BinaryStream, TextOutputStream, TextOutputStream, and TextInputStream. If you are using older APIs, you need to check the IOException property.
The ErrorNumber property of an IOException may be set to an OS error code.
The OS Status web site can help track down error code meanings.
In addition, you can use the
macerror command in Terminal to find a description of an error.
macerror -49 displays:
Mac OS error -49 (opWrErr): file already open with write permission
Windows error codes are available at MSDN.
Error Codes for Linux can be found here.
There are links to each OS’s specific error codes list. I’m assuming you’re on Windows, so if you follow the MSDN link you’ll see that error 3 is listed as:
The system cannot find the path specified.
How did I miss that stack of links??? Thansk @Anthony_G_Cyphers !