I don't know why but ActiveDocument.InlineShapes doesn't find InlineShapes for my document.
Anyhow ^g is working.
I tried this code from various earlier suggestions.
Code:
Sub BrokenImages2()
Application.ScreenUpdating = False
Dim StrTxt As String, HttpReq As Object, i As Long
Set HttpReq = CreateObject("Microsoft.XMLHTTP")
With ActiveDocument.Range
With .Find
.ClearFormatting
.Replacement.ClearFormatting
.Text = "^g"
.Replacement.Text = ""
.Forward = True
.Wrap = wdFindStop
.Format = False
.MatchWildcards = False
.Execute
End With
Do While .Find.Found
If .Hyperlinks.Count > 0 Then
s = .Hyperlinks(1).Address
MsgBox s
If InStr(s, "about") = 1 Then
s = Replace(.Hyperlinks(1).Address, "about", "HTTP")
MsgBox s
With Dialogs(wdDialogInsertPicture)
.Name = s
.Execute
End With
End If
End If
.Collapse wdCollapseEnd
.Find.Execute
Loop
End With
End Sub
This is inserting images at selection.
How to replace images that found with url images?