I am using a code that was working well as for this topic
This is part of the code
Code: Select all
With ThisWorkbook.Worksheets("INF")
objDoc.Content.Find.Execute findText:="XXXXX", ReplaceWith:=.Range("B3").Value, MatchWholeWord:=False, Replace:=2
objDoc.Content.Find.Execute findText:="YYYYY", ReplaceWith:=.Range("B5").Value, MatchWholeWord:=False, Replace:=2
End With
The problem is that the string in Arabic doesn't come correctly unless the direction of the writing is set to Arabic (by changng Shift + Alt ). How can this be automatically done via the code?