-
I already did counting of the codes now I cant figure out how to higlight non matching tags
Thnx
here is the code:
Sub d()
Dim iCount As Long
Dim strSearch As String
Dim nasel As Boolean
Dim lcount As Long
Dim Mcount As Long
Dim Mecount As Long
Dim numcount As Long
Dim numecount As Long
Dim art As Long
Dim arte As Long
Dim orig As Long
Dim orige As Long
'strSearch = InputBox$("Type in the text you want to search for.")
'iCount = 0
With ActiveDocument.Content.find
.Text = "<Amend>"
.Format = False
.Wrap = wdFindStop
.Style = ActiveDocument.Styles("HideTWBExt")
Do While .Execute
iCount = iCount + 1
Loop
End With
With ActiveDocument.Content.find
.Text = "</Amend>"
.Format = False
.Wrap = wdFindStop
.Style = ActiveDocument.Styles("HideTWBExt")
Do While .Execute
lcount = lcount + 1
Loop
End With
With ActiveDocument.Content.find
.Text = "<Members>"
.Format = False
.Wrap = wdFindStop
.Style = ActiveDocument.Styles("HideTWBExt")
Do While .Execute
Mcount = Mcount + 1
Loop
End With
With ActiveDocument.Content.find
.Text = "</Members>"
.Format = False
.Wrap = wdFindStop
.Style = ActiveDocument.Styles("HideTWBExt")
Do While .Execute
Mecount = Mecount + 1
Loop
End With
With ActiveDocument.Content.find
.Text = "<NumAm>"
.Format = False
.Wrap = wdFindStop
.Style = ActiveDocument.Styles("HideTWBExt")
Do While .Execute
numcount = numcount + 1
Loop
End With
With ActiveDocument.Content.find
.Text = "</NumAm>"
.Format = False
.Wrap = wdFindStop
.Style = ActiveDocument.Styles("HideTWBExt")
Do While .Execute
numecount = numecount + 1
Loop
End With
With ActiveDocument.Content.find
.Text = "<Article>"
.Format = False
.Wrap = wdFindStop
.Style = ActiveDocument.Styles("HideTWBExt")
Do While .Execute
artcount = artcount + 1
Loop
End With
With ActiveDocument.Content.find
.Text = "</Article>"
.Format = False
.Wrap = wdFindStop
.Style = ActiveDocument.Styles("HideTWBExt")
Do While .Execute
artecount = artecount + 1
Loop
End With
With ActiveDocument.Content.find
.Text = "<Original>"
.Format = False
.Wrap = wdFindStop
.Style = ActiveDocument.Styles("HideTWBExt")
Do While .Execute
origcount = origcount + 1
Loop
End With
With ActiveDocument.Content.find
.Text = "</Original>"
.Format = False
.Wrap = wdFindStop
.Style = ActiveDocument.Styles("HideTWBExt")
Do While .Execute
origecount = origecount + 1
Loop
End With
msgbox "<Amend>" & " sem na?el " & _
iCount & " krat" & vbCrLf & "</Amend>" & " sem na?el " & lcount _
& " krat " & vbCrLf & vbCrLf & "<Members>" & " sem na?el " & Mcount & " krat" & vbCrLf _
& "</Members>" & " sem na?el " & _
Mecount & " krat" & vbCrLf & vbCrLf & "<NumAm>" & " sem na?el " & _
numcount & " krat" & vbCrLf & "</NumAm>" & " sem na?el " & _
numecount & " krat" & vbCrLf & vbCrLf & "<Article>" & " sem na?el " & _
artcount & " krat" & vbCrLf & "</Article>" & " sem na?el " & _
artecount & " krat" & vbCrLf & vbCrLf & "<Original>" & " sem na?el " & _
origcount & " krat" & vbCrLf & "</Original>" & " sem na?el " & _
origecount & " krat"
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules