Confusing error E_UNEXPECTED(0x8000FFFF)
No error message available, result code: E_UNEXPECTED(0x8000FFFF).
I couldn't find any solutions through google. Encountered this w开发者_如何学Chile parsing an excel file. Does anyone know why this even occurs? It would be fine and all if it allowed me to recover from the error, but it even goes through the try catch and finally clause and renders my program useless!
Here's a more detailed question I asked yesterday that's related:
OleDb Object Invalid or No Longer Set
E_UNEXPECTED is usually returned on catastrophic failures. It means "I can't say what went wrong, but something is definitely wrong and I don't think you can do anything about it. Abort the program and get over it". Most of the time it is returned when some invariant is broken because of a bug or a failure to recognize defective input data (or parameters) lead to a corruption of internal data. Lazy programmers however return it when they don't feel like digging up a useful error value and simply return the most serious message available.
If the library you are using is usually supposed to work, then you should double check if you are using it the correct way.
I faced this error when my file got currupted. Please check yours.
精彩评论