I have been using the below code I found online to automatically pull images into excel from one of our network drives.

I've been attempting to make edits to the code, but my VBA knowledge is so limited - nothing has worked.

I need to make three changes.
1. I want it to embed the picture and not just link it(as it currently does)
2. I want the image to be centered within the cell and automatically "move and size" with the cell
3. Instead of looking in Column A for the image name, I want it to look in every cell between Column A and Column ZZ and then insert the images in the cell one row directly above the image name. (Example a match in Cell A9 would embed the image in cell A8)

Any help would be so appreciated.

Sub UpdatePictures()
Dim R As Range
Dim S As Shape
Dim Path As String, FName As String

'Setup the path
Path = "\\10.1.1.5\images"
'You can read this value also from a cell, e.g.:
'Path = Worksheets("Setup").Range("A1")

'Be sure the path has a trailing backslash
If Right(Path, 1) <> "\" Then Path = Path & "\"

'Visit each used cell in column A
For Each R In Range("A1", Range("A" & Rows.Count).End(xlUp))
'Try to get the shape
Set S = GetShapeByName(R)
'Found?
If S Is Nothing Then
'Find the picture e.g. "C:\temp\F500.*"
FName = Dir(Path & R & ".*")
'Found?
If FName <> "" Then
Set S = InsertPicturePrim(Path & FName, R)
End If
End If
If Not S Is Nothing Then
'Show the error if the name did not match the cell
If S.Name <> R Then R.Interior.Color = vbRed
With R.Offset(0, 1)
'Move the picture to the cell on the right side
S.Top = .Top
S.Left = .Left
'Resize it
S.Width = .Width

'Remove the aspect ratio by default if necessary
'S.LockAspectRatio = False

If S.LockAspectRatio Then
'Make it smaller to fit the cell if necessary
If S.Height > .Height Then S.Height = .Height
Else
'Stretch the picture
S.Height = .Height
End If
End With
'Move it behind anything else
S.ZOrder msoSendToBack
Else
R.Offset(0, 1) = "No picture available"
End If
Next
End Sub

Private Function GetShapeByName(ByVal SName As String) As Shape
'Return the shape with SName, Nothing if not exists
On Error Resume Next
Set GetShapeByName = ActiveSheet.Shapes(SName)
End Function

Private Function InsertPicturePrim(ByVal FName As String, ByVal SName As String) As Shape
'Inserts the picture, return the shape, Nothing if failed
Dim P As Picture
On Error Resume Next
'Insert the picture
Set P = ActiveSheet.Pictures.Insert(FName)
'Success?
If Not P Is Nothing Then
'Return the shape
Set InsertPicturePrim = P.ShapeRange(1)
'Rename it, so we can easily find it later
P.Name = SName
End If
End Function