0

We are running a old WPF application and due to some reasons stick with .NET 4.5 version only.

Using the following code, we are adding some custom dictionaries for every RichTextbox controls.

public void InitDictionary()
{
    var dictionaries = SpellCheck.GetCustomDictionaries(richText);
    if (dictionaries.Count == 0)
    {
        var dictionaryUri = TextBoxDictionary.DictionaryUri;
        if (dictionaryUri != null)
        {
            dictionaries.Add(dictionaryUri);
        }
    }
}

This code is working fine in Windows Server 2016 and Windows 10 1670 version.

But same code is NOT working in Windows Server 2019 and latest versions of Windows 10.

For now, we could not update our application to .Net 4.6.1 or latest version

Since it is working fine in older version of Windows, suspect it is known issue with latest Windows OS. Please correct me if I'm wrong.

Is there any solid fix available without going for third party controls?

Thanks in advance.

6
  • How does it fail? Commented Aug 1, 2023 at 11:27
  • 2
    .Net framework 4.5 is not longer supported. So there should be no expectation that it should work on the latest windows versions. You cannot blame windows if unsupported frameworks does not work. Commented Aug 1, 2023 at 11:28
  • I suspect the custom dictionary is part of Word and the issue may be with word not installed. See : answers.microsoft.com/en-us/msoffice/forum/all/… Commented Aug 1, 2023 at 12:34
  • Custom spell check dictionary in Wpf has nothing to do with word. Commented Aug 1, 2023 at 18:42
  • agree with @JonasH. thanks! Commented Aug 2, 2023 at 4:32

1 Answer 1

0

Finally we identified that, there is some size limitation on user custom dictionary in Windows!

We are using bigger custom dictionary files (nearly 2mb). And by the following (MS recommended) registry fix is resolving our issue.

HKEY_CURRENT_USER\Software\Microsoft\Spelling\Dictionaries\AllowBiggerUD=1

AllowBiggerUD as DWORD 32-bit

https://learn.microsoft.com/en-us/windows/win32/api/spellcheck/nn-spellcheck-iuserdictionariesregistrar#remarks

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.