Changing language of textboxes

S

Steve Barber

I regularly receive documents from French colleagues - The first job I have
to do is check their spelling. I have a macro that will select all the text
and tables and change their language setting to wdEnglishUK it will not,
however, cope with text boxes can anyone tell me (with code example please)
how to achieve this?

Many thanks in advance
 
J

Jay Freedman

I regularly receive documents from French colleagues - The first job I have
to do is check their spelling. I have a macro that will select all the text
and tables and change their language setting to wdEnglishUK it will not,
however, cope with text boxes can anyone tell me (with code example please)
how to achieve this?

Many thanks in advance

Hi Steve,

Add this code to your macro:

Dim oTB As Shape
For Each oTB In ActiveDocument.Shapes
If oTB.Type = msoTextBox Then
oTB.TextFrame.TextRange.LanguageID = wdEnglishUK
End If
Next oTB
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top