# C1.WPF.SpellChecker.C1SpellChecker.BadWordFound

## Content

<div class="doc-site-dotnet-api-container">




<h1 id="C1_WPF_SpellChecker_C1SpellChecker_BadWordFound" data-uid="C1.WPF.SpellChecker.C1SpellChecker.BadWordFound" class="text-break">BadWordFound Event
</h1>
<div class="markdown level0 summary"><p>Event that fires when a spelling error is found by the <a class="xref" href="C1.WPF.SpellChecker.C1SpellChecker.html">C1SpellChecker</a>.</p>
</div>
<div class="markdown level0 conceptual"></div>
<h6><strong>Namespace</strong>: <a class="xref" href="C1.WPF.SpellChecker.html">C1.WPF.SpellChecker</a></h6>
<h6><strong>Assembly</strong>: C1.WPF.SpellChecker.4.6.2.dll</h6>
<h5 id="C1_WPF_SpellChecker_C1SpellChecker_BadWordFound_syntax">Syntax</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public event BadWordEventHandler BadWordFound</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Event BadWordFound As BadWordEventHandler</code></pre>
</div>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="C1.WPF.SpellChecker.BadWordEventHandler.html">BadWordEventHandler</a></td>
      <td>Event that fires when a spelling error is found by the .</td>
    </tr>
  </tbody>
</table>
<h5 id="C1_WPF_SpellChecker_C1SpellChecker_BadWordFound_remarks"><strong>Remarks</strong></h5>
<div class="markdown level0 remarks"><pre><code>&lt;p&gt;This event fires when the component detects a spelling error in a control. 
</code></pre>
<p>This happens while a spell dialog is displayed (see the <a class="xref" href="C1.WPF.SpellChecker.C1SpellChecker.CheckControlAsync.html#C1_WPF_SpellChecker_C1SpellChecker_CheckControlAsync_System_Object_">CheckControlAsync(object)</a>
method) or while the component is painting the red wavy underlines that mark misspelled words
in dynamic mode (see the <a class="xref" href="C1.WPF.SpellChecker.SpellOptions.ActiveSpellingEnabled.html#C1_WPF_SpellChecker_SpellOptions_ActiveSpellingEnabled">ActiveSpellingEnabled</a> property).</p>
<p>The event parameters have a <b>Dialog</b> property that allow the handler to determine
whether a spell dialog is being displayed or not.</p>
<p>The event parameters also have a <b>Cancel</b> property that can be used to ignore
the error.</p>
<p>Note that this event fires every time a misspelled word is about to be underlined,
which occurs whenever the control is painted (not just when the bad word is initially
typed into the control. Because of this, one single misspelled word can cause this event
to fire multiple times.</p>
</div>
</div>
