I got stuck at one place.If I compare 2 documents entirely(not page by page) how will I get the page numbers where we have the discrepancies.In the below mentioned code I want the page number to be return which are not matching with each other.I tried it but I failed.
dim temp as string
dim temp1 as string
Set objWord = CreateObject("Word.Application")
Set objDoc = objWord.Documents.Open(TextBox1.Text)
temp = objDoc.Range(0, objDoc.Range.End)
objWord.Quit
Dim objword1 As Object
Set objword1 = CreateObject("Word.Application")
Set objDoc1 = objword1.Documents.Open(TextBox2.Text)
temp1 = objDoc1.Range(0, objDoc1.Range.End)
objword1.Quit
If temp = temp1 Then
MsgBox "Matched", vbInformation
Else
MsgBox "Not Matched", vbInformation
End If
Bookmarks