# HtmlConversionLimitException

Thrown when HTML conversion input exceeds a configured safety or resource limit.

Class 

`OfficeIMO.Word.Html`

**Namespace**

`OfficeIMO.Word.Html`

**Assembly**

`OfficeIMO.Word.Html`

**Source revision**

`013c05ace7bb` with working tree changes

**Source**

[HtmlToWordOptions.cs:629](https://github.com/EvotecIT/OfficeIMO/blob/013c05ace7bb14e293639941ec9cf54eb5177a90/OfficeIMO.Word.Html/Options/HtmlToWordOptions.cs#L629)

**Base**

`InvalidOperationException`

**Implements**

`ISerializable`

**Modifiers**

sealed

Thrown when HTML conversion input exceeds a configured safety or resource limit.

## Inheritance

- InvalidOperationException
- HtmlConversionLimitException

Filter members 

Show inherited

## Constructors

`public HtmlConversionLimitException(string code, string message, string source, long actual, long limit, string? detail = null)` [#](#constructor-ctor-string-string-string-int64-int64-string)

[HtmlToWordOptions.cs:629](https://github.com/EvotecIT/OfficeIMO/blob/013c05ace7bb14e293639941ec9cf54eb5177a90/OfficeIMO.Word.Html/Options/HtmlToWordOptions.cs#L629)

Creates a conversion limit exception.

Parameters

**code string required**

Stable diagnostic code associated with the limit.

**message string required**

Human-readable message.

**source string required**

Configured limit or resource source that was exceeded.

**actual long required**

Observed value.

**limit long required**

Configured limit.

**detail string? = null optional**

Optional formatted detail.

## Inherited Methods

`public virtual bool Equals(object? obj)` [#](#method-equals-object)

Inherited from object

Parameters

**obj object? required**

Returns

`bool`

`public virtual Exception GetBaseException()` [#](#method-getbaseexception)

Inherited from Exception

Returns

`Exception`

`public virtual int GetHashCode()` [#](#method-gethashcode)

Inherited from object

Returns

`int`

`public virtual void GetObjectData(SerializationInfo info, StreamingContext context)` [#](#method-getobjectdata-serializationinfo-streamingcontext)

Inherited from Exception

`Obsolete("This API supports obsolete formatter-based serialization. It should not be called or extended by application code.", DiagnosticId = "SYSLIB0051", UrlFormat = "https://aka.ms/dotnet-warnings/{0}")` `EditorBrowsable(1)`

Parameters

**info SerializationInfo required**

**context StreamingContext required**

`public Type GetType()` [#](#method-gettype)

Inherited from Exception

Returns

`Type`

`public override string ToString()` [#](#method-tostring)

Inherited from Exception

Returns

`string`

## Properties

`public string Code { get; }` [#](#property-code)

[HtmlToWordOptions.cs:640](https://github.com/EvotecIT/OfficeIMO/blob/013c05ace7bb14e293639941ec9cf54eb5177a90/OfficeIMO.Word.Html/Options/HtmlToWordOptions.cs#L640)

Stable diagnostic code associated with the limit.

`public string LimitSource { get; }` [#](#property-limitsource)

[HtmlToWordOptions.cs:645](https://github.com/EvotecIT/OfficeIMO/blob/013c05ace7bb14e293639941ec9cf54eb5177a90/OfficeIMO.Word.Html/Options/HtmlToWordOptions.cs#L645)

Configured limit or resource source that was exceeded.

`public long Actual { get; }` [#](#property-actual)

[HtmlToWordOptions.cs:650](https://github.com/EvotecIT/OfficeIMO/blob/013c05ace7bb14e293639941ec9cf54eb5177a90/OfficeIMO.Word.Html/Options/HtmlToWordOptions.cs#L650)

Observed value.

`public long Limit { get; }` [#](#property-limit)

[HtmlToWordOptions.cs:655](https://github.com/EvotecIT/OfficeIMO/blob/013c05ace7bb14e293639941ec9cf54eb5177a90/OfficeIMO.Word.Html/Options/HtmlToWordOptions.cs#L655)

Configured limit.

`public string? Detail { get; }` [#](#property-detail)

[HtmlToWordOptions.cs:660](https://github.com/EvotecIT/OfficeIMO/blob/013c05ace7bb14e293639941ec9cf54eb5177a90/OfficeIMO.Word.Html/Options/HtmlToWordOptions.cs#L660)

Optional formatted detail.

## Inherited Properties

`public MethodBase? TargetSite { get; }` [#](#property-targetsite)

Inherited from Exception

`public virtual string Message { get; }` [#](#property-message)

Inherited from Exception

`public virtual IDictionary Data { get; }` [#](#property-data)

Inherited from Exception

`public Exception? InnerException { get; }` [#](#property-innerexception)

Inherited from Exception

`public virtual string? HelpLink { get; set; }` [#](#property-helplink)

Inherited from Exception

`public virtual string? Source { get; set; }` [#](#property-source)

Inherited from Exception

`public int HResult { get; set; }` [#](#property-hresult)

Inherited from Exception

`public virtual string? StackTrace { get; }` [#](#property-stacktrace)

Inherited from Exception

<!-- PowerForge markdown artifact sha256:7B8C0096D44B3631B84F2EE270911B594AE91DE6CDB8ADD8A4EC189EE47565EC -->
