removing parallel cites from legal documentation

P

Peter

I'm interested in removing "parallel citations" from some legal
documents (is there by any chance a freely-available
regular-expressions add-on for Word?). That is, I'd like (roughly)
to change:

[::digits::] [::alpha::] [::digits::] ([::digits::]), {same thing
repeated once or twice}

to:

[::digits::] [::alpha::] [::digits::] ([::digits::])

This may in fact be impossible as a general matter, because of the
great diversity of citation formats, but if anyone has had any luck
chopping parallels cites down to a manageable size I would love to
hear about it.

Thanks!
 
H

Helmut Weber

Hi Peter,

it all depends on the consistency,
the regularity of your text.

Here is my sample text:

7,3 Mrd 333aaa444555666, 333aaa444555666, 333aaa444555666, 333aaa444555666.
Euro zu,
so Frithjof Staiß, Leiter der AG Statistik legten im gleichen Zeitraum sogar
um 38 % auf 7,3 Mrd 333aaa444555666, 333aaa444555666, 333aaa444555666,
333aaa444555666.

And for this text, the following code seems to work.

Sub test0987()
Dim rDcm As Range
Set rDcm = ActiveDocument.Range
Dim Str1 As String
Dim Str2 As String
Dim Str3 As String

With rDcm.Find
.Text = "[0-9]{1;}[a-z]{1;}[0-9]{1;}"
.MatchWildcards = True
While .Execute
rDcm.Select
Str1 = rDcm.Text
Str2 = Str1 & ", "
Str3 = Str2 & Str1
With ActiveDocument.Range.Find
.Text = Str3
.MatchWildcards = False
.Replacement.Text = Str1
.Execute Replace:=wdReplaceAll
End With
Wend
End With
End Sub

Need more info or clarification?
Ask again.
 
H

Helmut Weber

hmm...

always the same problem with the listseperator.

This is the German version:
.Text = "[0-9]{1;}[a-z]{1;}[0-9]{1;}" and this is the US-version:
.Text = "[0-9]{1,}[a-z]{1,}[0-9]{1,}"

--
Greetings from Bavaria, Germany

Helmut Weber, MVP WordVBA

Win XP, Office 2003
"red.sys" & Chr$(64) & "t-online.de"
 
J

Jezebel

Word's Find and Replace, with 'Use Wildcards' checked, uses regular
expressions.
 
C

Charles Kenyon

What you describe is not what I call parallel cites but duplicate. Parallel
cites are citations to the same authority published in a different location
so they would not be the same thing repeated.

And no, I don't know of any way to remove such duplications automatically.
It is too complex for Word's duplicate word checking. You can use find and
replace, but this is a semi-manual solution.
--
Charles Kenyon

Word New User FAQ & Web Directory: http://addbalance.com/word

Intermediate User's Guide to Microsoft Word (supplemented version of
Microsoft's Legal Users' Guide) http://addbalance.com/usersguide


--------- --------- --------- --------- --------- ---------
This message is posted to a newsgroup. Please post replies
and questions to the newsgroup so that others can learn
from my ignorance and your wisdom.
 

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