Y
Yannick
When I click on the button of the macro or press the
shortcut keyboard to insert a bookmark (I created that
macro in Visual Basic), I get immediately a dialog box
saying "Compile error", I press OK and appears the window
code showing hte macro. The first line "Bookmarks()" is
yellow highligted and "t =" selected in black.
Could somebody tell me what does that mean and above all
how to fix it.
This is the macro:
---------------------------------------------------
Bookmarks()
t = Selection.Text
With ActiveDocument.Bookmarks
.Add Range:=Selection.Range, Name:="b" & t
.DefaultSorting = wdSortByName
.ShowHidden = False
End With
Selection.MoveDown Unit:=wdLine, Count:=1
End Sub
shortcut keyboard to insert a bookmark (I created that
macro in Visual Basic), I get immediately a dialog box
saying "Compile error", I press OK and appears the window
code showing hte macro. The first line "Bookmarks()" is
yellow highligted and "t =" selected in black.
Could somebody tell me what does that mean and above all
how to fix it.
This is the macro:
---------------------------------------------------
Bookmarks()
t = Selection.Text
With ActiveDocument.Bookmarks
.Add Range:=Selection.Range, Name:="b" & t
.DefaultSorting = wdSortByName
.ShowHidden = False
End With
Selection.MoveDown Unit:=wdLine, Count:=1
End Sub