Question : How do I position a drawing canvas in MS Word 2010

I had a macro in Word 2007 which dumped a particular drawing behind my page. The same macro in 2010 has shrunk the drawing, and positioned the top left corner about an inch outside the actual page.

My code is below. I've added in the anchoring lines, but they're not changing anything.
1:
2:
3:
4:
5:
6:
7:
8:
9:
Dim shpCanvas As Shape
          
    Set shpCanvas = ActiveDocument.Shapes.AddCanvas(Left:=0, Top:=0, Width:=860, Height:=596)
    
    shpCanvas.RelativeHorizontalPosition = wdRelativeHorizontalPositionPage
    shpCanvas.RelativeVerticalPosition = wdRelativeVerticalPositionPage
    
    shpCanvas.CanvasItems.AddPicture FileName:="C:\CompanyData\InternalDocs\graphics\Letterhead.jpeg", LinkToFile:=False, SaveWithDocument:=True, Left:=0, Top:=0, Width:=596, Height:=860
    shpCanvas.WrapFormat.Type = wdWrapBehind

Answer : How do I position a drawing canvas in MS Word 2010

Oops. Here is the code.
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
Sub InsertPicture()
    Dim doc As Word.Document
    Dim Sh As Shape
    Dim PicFile As String
    Dim rng As Range
    
    Application.ScreenUpdating = False
        Set doc = ActiveDocument
        Set rng = doc.Paragraphs(1).Range
        PicFile = "J:\My Pictures\Al\DSCF1882.jpg"
        Set Sh = doc.Shapes.AddPicture(PicFile, False, True, , , , , rng)
        With Sh
            .RelativeHorizontalPosition = wdRelativeHorizontalPositionPage
            .RelativeVerticalPosition = wdRelativeVerticalPositionPage
            .LockAspectRatio = True
            .Left = 0
            .Top = 0
            .Width = rng.PageSetup.PageWidth
            .WrapFormat.Type = wdWrapBehind
            .Name = "David Bailey Photo 1.jpg"
        End With
    Application.ScreenUpdating = True

End Sub
Random Solutions  
 
programming4us programming4us