CustomLabels Property Example

This example creates a new custom label named "AdminAddress" and then creates a page of mailing labels using a predefined return address.

addr = "Administration" & vbCr & "Mail Stop 22-16"
Set myLabel = Application.MailingLabel _
    .CustomLabels.Add(Name:="AdminAddress", DotMatrix:= False)
With myLabel
    .Height = InchesToPoints(0.5)
    .Width = InchesToPoints(1)
    .HorizontalPitch = InchesToPoints(2.06)
    .VerticalPitch = InchesToPoints(0.5)
    .NumberAcross = 4
    .NumberDown = 20
    .PageSize = wdCustomLabelLetter
    .SideMargin = InchesToPoints(0.28)
    .TopMargin = InchesToPoints(0.5)
End With
Application.MailingLabel.CreateNewDocument _
    Name:="AdminAddress", Address:=addr