Checks if the document is valid.
The instance of Doc to check
If the specified document handle is valid, it returns true. Otherwise, it returns false and error-handler is called.
See Implementation
Checks if the document is valid.