title | keywords | f1_keywords | api_name | ms.assetid | ms.date | ms.localizationpriority | ||
---|---|---|---|---|---|---|---|---|
PageSetup.RightFooterPicture property (Excel) |
vbaxl10.chm473111 |
|
|
f33bbfb1-91d0-6724-0944-2b63c6720d86 |
05/03/2019 |
medium |
Returns a Graphic object that represents the picture for the right section of the footer. Used to set attributes of the picture.
expression.RightFooterPicture
expression A variable that represents a PageSetup object.
The RightFooterPicture property itself is read-only, but not all of its properties are read-only.
It's required that "&G"
be a part of the RightFooter property string for the image to show up in the right footer.
The following example adds a picture titled Sample.jpg from the C:\ drive to the right section of the footer. This example assumes that a file called Sample.jpg exists on the C:\ drive.
Sub InsertPicture()
With ActiveSheet.PageSetup.RightFooterPicture
.FileName = "C:\Sample.jpg"
.Height = 275.25
.Width = 463.5
.Brightness = 0.36
.ColorType = msoPictureGrayscale
.Contrast = 0.39
.CropBottom = -14.4
.CropLeft = -28.8
.CropRight = -14.4
.CropTop = 21.6
End With
' Enable the image to show up in the right footer.
ActiveSheet.PageSetup.RightFooter = "&G"
End Sub
[!includeSupport and feedback]