Link word document with VBScript

Hi Team,

I have a screenshot in the word document and i need to add border for that. So I have added a VBScript and i want to invoke that.
I used invoke VB Script but still changes are not getting reflected.

Please correct me if i am missing something.


Below is the script that i have in vb script file

Sub Border()
Dim i As Long, j As Long
With ActiveDocument.Range
For i = 1 To .InlineShapes.Count
With .InlineShapes(i)
.Borders(1).LineStyle = wdLineStyleSingle
.Borders(1).Color = wdColorAutomatic
End With
Next i
End With
End Sub