Hi
ich versuche ein Makro zu schreiben, das meinen roten text der Lutherbibel 1545 in die Fußnote verlegt. Es funktioniert einmal, aber dann steht der Cursor in der Fußnote und kommt nicht mehr in den Haupttext zurück. habt ihr eine Idee? Es wäre auch gut wenn das Makro mehrfach hintereinander bis zum Ende ausgeführt wird.
Sub Sascha1()
'
' Sascha1 Makro
'
'
Selection.Find.ClearFormatting
With Selection.Find.Font
.Italic = True
.Color = 192
End With
Selection.Find.Replacement.ClearFormatting
With Selection.Find
.Text = ""
.Replacement.Text = ""
.Forward = True
.Wrap = wdFindContinue
.Format = True
.MatchCase = False
.MatchWholeWord = False
.MatchKashida = False
.MatchDiacritics = False
.MatchAlefHamza = False
.MatchControl = False
.MatchWildcards = False
.MatchSoundsLike = False
.MatchAllWordForms = False
End With
Selection.Find.Execute
Selection.Cut
With Selection
With .FootnoteOptions
.Location = wdBottomOfPage
.NumberingRule = wdRestartContinuous
.StartingNumber = 1
.NumberStyle = wdNoteNumberStyleArabic
End With
.Footnotes.Add Range:=Selection.Range, Reference:=""
End With
Selection.PasteAndFormat (wdFormatPlainText)
End Sub