• Change Spelling Language (Excel 2000)

    • This topic has 3 replies, 2 voices, and was last updated 20 years ago.
    Author
    Topic
    #418243

    To spell check a range of cells, I have included the following in my code:
    rRange.CheckSpelling CustomDictionary:=”CUSTOM.DIC”, IgnoreUppercase:=False _
    , AlwaysSuggest:=True, SpellLang:=1033
    It works fine. But now I’d like to change the language for this spell check, and change it back in the workbook close event.
    The “SpellLang” method suggests there’s a way, but I can’t find anything in help or in the KB other than ways of displaying the language in use (for the install language, the user interface language, or the Help language).
    I know the UI does not provide a way to change the language as it does in Word.
    Any ideas?

    Viewing 0 reply threads
    Author
    Replies
    • #940701

      In Excel 2002, you can use

      Application.SpellingOptions.DictLang = 1033

      but I’m not sure if that was available in Excel 2000.

      • #940946

        Hans,
        No, Excel 2000 does not support this method, so I can’t see a way to set things up in workbook or sheet events.
        The first thing I was looking for, was the ID for the language I wanted. As is often the case, it was much easier simply to use the macro recorder while changing the language to what I wanted and then look at the code to get the ID, than to search the KB and TechNet where I found nothing.
        That done, I find that I can run the spell checker for my preferred language:
        Cells(19, 2).CheckSpelling CustomDictionary:=”CUSTOM.DIC”, IgnoreUppercase:=False _
        , AlwaysSuggest:=True, SpellLang:=3084
        The next problem is to turn the language back to English. This is done by invoking the spell checker a second time:
        Cells(19, 2).CheckSpelling CustomDictionary:=”CUSTOM.DIC”, IgnoreUppercase:=False _
        , AlwaysSuggest:=True, SpellLang:=1033
        It means the user has to be aware of this, and when they see the change of language at the bottom of the dialog box, to click Cancel. It happens too fast for the user to notice that the spell checker has actually started again. Not perfect, but workable.
        A related issue in my case, is that when I restrict the spell check to a specific range of cells, it won’t work if the cells are merged. So my procedure un-merges the cells and re-merges them when the user is finished spelling. This works, but introduces a further irritant: the word being checked is isolated and none of the rest of the text can be seen, denying the user the context. Maybe they can get used to this too???

        • #940968

          Another reason to avoid merging cells… (or move to Excel 2002 or 2003)

    Viewing 0 reply threads
    Reply To: Change Spelling Language (Excel 2000)

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: