S
Soniya
Hi all,
I found several post here describing how to declare a range in Word.
But when itried to declare a word range (Dim myRange As Word.Range) it
gives me an error !?
I am using office 2003 with windows xp.
I could not select a paragraph in word for formatting or my desired
format does not work in word.
With WDApp
.Documents.Add
With .Selection
.TypeText Text:=A
.Font.Name = "Simplified Arabic"
.Font.Size = 18
.Font.Bold = True
.ParagraphFormat.Alignment = 1
.TypeParagraph
.ParagraphFormat.Alignment = 2
.TypeParagraph
.Font.Size = 14
.Font.Bold = False
.Font.Name = "Simplified Arabic"
.TypeText Text:=B
.TypeParagraph
If CmbPrint = "Arabic + Malayalam" Then
.TypeParagraph
.ParagraphFormat.Alignment = 0
.Font.Size = 14
.Font.Bold = False
.Font.Name = "ML-TTKarthika"
.TypeText Text:=C
ElseIf CmbPrint = "Arabic + English" Then
.TypeParagraph
.ParagraphFormat.Alignment = 0
.Font.Name = "Times New Roman"
.Font.Bold = False
.Font.Size = 11
.TypeText Text:=C
ElseIf CmbPrint = "Arabic + Urdu" Then '
.TypeParagraph
.ParagraphFormat.Alignment = 2
.Font.Name = "HUrdu Nastaliq"
.Font.Bold = False
.TypeText Text:=C
.Font.Size = 16
End If
End With
Here Arabic and Urdu are right to left and English and Malayalam left
to right
When it write the data to word one my fist part (text A) only three
charecters are font size 18 and remaining default. Also text B and C
also not giving me desired formatting.
any help?
TIA
Soniya
I found several post here describing how to declare a range in Word.
But when itried to declare a word range (Dim myRange As Word.Range) it
gives me an error !?
I am using office 2003 with windows xp.
I could not select a paragraph in word for formatting or my desired
format does not work in word.
With WDApp
.Documents.Add
With .Selection
.TypeText Text:=A
.Font.Name = "Simplified Arabic"
.Font.Size = 18
.Font.Bold = True
.ParagraphFormat.Alignment = 1
.TypeParagraph
.ParagraphFormat.Alignment = 2
.TypeParagraph
.Font.Size = 14
.Font.Bold = False
.Font.Name = "Simplified Arabic"
.TypeText Text:=B
.TypeParagraph
If CmbPrint = "Arabic + Malayalam" Then
.TypeParagraph
.ParagraphFormat.Alignment = 0
.Font.Size = 14
.Font.Bold = False
.Font.Name = "ML-TTKarthika"
.TypeText Text:=C
ElseIf CmbPrint = "Arabic + English" Then
.TypeParagraph
.ParagraphFormat.Alignment = 0
.Font.Name = "Times New Roman"
.Font.Bold = False
.Font.Size = 11
.TypeText Text:=C
ElseIf CmbPrint = "Arabic + Urdu" Then '
.TypeParagraph
.ParagraphFormat.Alignment = 2
.Font.Name = "HUrdu Nastaliq"
.Font.Bold = False
.TypeText Text:=C
.Font.Size = 16
End If
End With
Here Arabic and Urdu are right to left and English and Malayalam left
to right
When it write the data to word one my fist part (text A) only three
charecters are font size 18 and remaining default. Also text B and C
also not giving me desired formatting.
any help?
TIA
Soniya