SpellChecker eigene Wörter hinzufügen.

Einbindung von Office-Komponenten wie Word, Excel usw.

Moderator: Moderatoren

Antworten
Benutzeravatar
AUGE_OHR
Marvin
Marvin
Beiträge: 12903
Registriert: Do, 16. Mär 2006 7:55
Wohnort: Hamburg
Hat sich bedankt: 19 Mal
Danksagung erhalten: 44 Mal

SpellChecker eigene Wörter hinzufügen.

Beitrag von AUGE_OHR »

hi,

Wenn man bei Word den SpellChecker benutzt kann man eigene Wörter hinzufügen.

das ActiveX Demo von Alaska hat keinen Button dafür also dachte ich mir lass den Macro Editor in Word mitlaufen. also gestartet und mit F7 die Rechtschreibprüfung mit dem Test Text. neue Wörter aufgenommen etc ... dann Macro Stop und ansehen.

leider steht da nur Activedocument.CheckGrammar aber vom Rest wurde nichts aufgezeichnet :-(

ich habe versucht unter "Add ..." zu gucken aber nichts passendes ?
hat jemand eine Idee wie die Methode zum abspeichern eigener Wörter im Wörterbuch (privat) von Word heisst ?

---

Zur Methode o:CheckSpelling(), welche das Alaska Demo benutzt, seit noch bemerkt das viel mehr Parameter gingt als nur den String zum prüfen
ShowCheckSpelling method as it applies to the Document and Range objects.

Begins a spelling check for the specified document or range. If the document or range contains errors, this method displays the Spelling and Grammar dialog box (Tools menu), with the Check grammar check box cleared. For a document, this method checks all available stories (such as headers, footers, and text boxes).

expression.CheckSpelling(CustomDictionary, IgnoreUppercase, AlwaysSuggest, CustomDictionary2, CustomDictionary3, CustomDictionary4, CustomDictionary5, CustomDictionary6, CustomDictionary7, CustomDictionary8, CustomDictionary9, CustomDictionary10)

expression Required. An expression that returns a Document or Range object.

CustomDictionary Optional Variant. Either an expression that returns a Dictionary object or the file name of the custom dictionary.

IgnoreUppercase Optional Variant. True if capitalization is ignored. If this argument is omitted, the current value of the IgnoreUppercase property is used.

AlwaysSuggest Optional Variant. True for Microsoft Word to always suggest alternative spellings. If this argument is omitted, the current value of the SuggestSpellingCorrections property is used.

CustomDictionary2 – CustomDictionary10 Optional Variant. Either an expression that returns a Dictionary object or the file name of an additional custom dictionary. You can specify as many as nine additional dictionaries.

Example
ShowAs it applies to the Range object.

This example begins a spelling check on all available stories of the active document.

Code: Alles auswählen

Set range2 = Documents("MyDocument.doc").Sections(2).Range
range2.CheckSpelling IgnoreUpperCase:=False, _
    CustomDictionary:="MyWork.Dic", _
    CustomDictionary2:="MyTechnical.Dic"
gruss by OHR
Jimmy
Antworten