none
change langauge editing RRS feed

  • Question

  • Hi all,

    in the new word office 2013, im currently making a macro wherein it checks the list of editing languages. I only want English UK to be displayed and remove all the others

    Is there any way to create using Macro

    Thanks

    Leroy M

    Thursday, December 5, 2013 2:01 PM

Answers

  • Hi Leroy

    Are you asking how to check the language(s) used for editing in the document? Or how to affect the list of languages the Word application shows to the user and lets them apply to the text?

    I don't think there's any way to do the latter - this list is hard-coded into Word and doesn't even depend on whether the language is available in the current configuration. You'd have to lock out Word's built-in interface (and I'm not even sure that's possible) and provide your own.

    But even then, depending on what language(s) the user has activated under Windows and what language was set as the default when a document (or its template) was created, other languages can show up almost randomly in a document...


    Cindy Meister, VSTO/Word MVP, my blog

    Friday, December 6, 2013 3:36 PM
    Moderator

All replies

  • Hello Leroy,

    Yes, there is. It looks like you are interested in the Range.DetectLanguage method which the Word Object Model provides:

    The method analyzes the specified text to determine the language that it is written in. The results of the DetectLanguage method are stored in the LanguageID property on a character-by-character basis. To read the LanguageID property, you must first specify a selection or range of text.

    After detecting languages you can remove other characters/words/sentences and etc.

    Thursday, December 5, 2013 9:36 PM
  • Hi Leroy

    Are you asking how to check the language(s) used for editing in the document? Or how to affect the list of languages the Word application shows to the user and lets them apply to the text?

    I don't think there's any way to do the latter - this list is hard-coded into Word and doesn't even depend on whether the language is available in the current configuration. You'd have to lock out Word's built-in interface (and I'm not even sure that's possible) and provide your own.

    But even then, depending on what language(s) the user has activated under Windows and what language was set as the default when a document (or its template) was created, other languages can show up almost randomly in a document...


    Cindy Meister, VSTO/Word MVP, my blog

    Friday, December 6, 2013 3:36 PM
    Moderator
  • Hi,

    Apologies for not being clear.

    Actually I'm creating the macro in PowerPoint.

    Let me explain again,

    If there are other preferred editing languages in PowerPoint, need them to be replaced by English UK and run the spell check again.

    This is mainly for the difference between US English and UK English.

    Is that possible

    Thanks

    Leroy M

    Saturday, December 7, 2013 3:12 PM
  • Hi Leroy

    Mmm, you've posted in the Word forum and your original question is about Word. If you really mean PowerPoint then we should move your question to a more appropriate forum?


    Cindy Meister, VSTO/Word MVP, my blog

    Saturday, December 7, 2013 3:31 PM
    Moderator
  • Hi Mascarenhas,

    Based on the question in your first post, I think Cindy have provided a proper reply. There is no method or property to remove the other specify language in Object Model. So I will temporarily close this case and mark the useful reply as answer.

    If you have more questions about PowerPoint development, I suggest you to post a new thread in the forum to involve more partners of this community to share their knowledge.


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Thursday, December 19, 2013 7:28 AM
    Moderator