Reputation: 279
I have Microsoft Office Professional Plus 2019 installed in Windows 10 Enterprise.
I used "CheckSpelling" method in calling a spellchecker dialog in a c# windows form application, however, the "Not in Dictionary" text area is empty and disabled (which should not be!). But when I was using Office 2016, "Not in Dictionary" was not empty and disabled. Do you know why it is empty and disabled? What is the solution or workaround for this?
Below is the c# code I used in a windows form application for opening a spell checker dialog of MS Word and image. I also tried using Office 16 interop word DLL but it is still the same issue.
Application wordApp = new Application();
object template = Missing.Value;
object newTemplate = Missing.Value;
object documentType = Missing.Value;
object visible = true;
object optional = Missing.Value;
_Document doc = wordApp.Documents.Add(ref template, ref newTemplate, ref documentType, ref visible);
doc.Words.First.InsertBefore(input);
ProofreadingErrors pe = doc.SpellingErrors;
int errorCount = pe.Count;
doc.CheckSpelling(ref optional, ref optional, ref optional, ref optional,
ref optional, ref optional, ref optional, ref optional, ref optional,
ref optional, ref optional, ref optional);
Thank you.
Upvotes: 0
Views: 258
Reputation: 9
When I keep Word minimized so that only the spelling and grammar check is visible the box is disabled.
There's two workarounds:
Here's a better workaround after spending more time with it:
You could move it to a different corner of the screen to try to better hide it. But, the Word window has to be on the screen. If you restore it to a location that's off-screen, then the bug is still there.
Upvotes: 0