Microsoft SDK for Java

ComException Class Constructors

The ComException contains the following constructors:

ComException(int hr)
ComException(int hr, String description)
ComException(int hr, String source, String helpFile,int helpContext)
ComException(int hr, String description, String source, String helpFile, int helpContext)
ComException()
ComException(String description)

ComException(int hr)

Creates a ComException object that contains the specified HRESULT.

Syntax

public ComException(int hr);

Parameters

hr The HRESULT value.

ComException(int hr, String description)

Creates a ComException object that contains an HRESULT and a description.

Syntax

public ComException(int hr, String description);

Parameters

hr The HRESULT value that is returned.
description The detail description.

ComException(int hr, String source, String helpFile, int helpContext)

Creates a ComException object that contains the HRESULT, source, Help file, and help context.

Syntax

public ComException(int hr, String source, String helpFile, int helpContext);

Parameters

hr The HRESULT value that is returned.
source The source of the ComException object.
helpFile The Help file that explains the ComException object.
helpContext The identifier that indicates the context of the exception.

ComException(int hr, String description, String source, String helpFile, int helpContext)

Creates a ComException object that contains the specified HRESULT, description, source, Help file, and Help context.

Syntax

public ComException(int hr, String description, String source, String helpFile, int helpContext);

Parameters

hr The HRESULT value to be returned.
description The detail description.
source The source of the ComException object.
helpFile The Help file that explains the ComException object.
helpContext The identifier that indicates the context of the exception.

ComException()

Creates and stores an uninitialized ComException object.

Syntax

public ComException();

ComException(String description)

Creates and stores a ComException object that contains the detail description.

Syntax

public ComException(String description);

Parameters

description The detail description.

© 1999 Microsoft Corporation. All rights reserved. Terms of use.