TableBackground Interface

Represents the background associated with a Table object.

Namespace:  Microsoft.Office.Interop.PowerPoint
Assembly:  Microsoft.Office.Interop.PowerPoint (in Microsoft.Office.Interop.PowerPoint.dll)

Syntax

'Declaration
<GuidAttribute("914934F8-5A91-11CF-8700-00AA0060263B")> _
Public Interface TableBackground
'Usage
Dim instance As TableBackground
[GuidAttribute("914934F8-5A91-11CF-8700-00AA0060263B")]
public interface TableBackground

Remarks

Use the Background property of a DataTable object to return the TableBackground object associated with the table.

To get a Table object from an existing shape, use the Table property of the CanvasShapes or ShapeRange object that contains the table. You can create a shape that contains a table by using the AddTable(Int32, Int32, Single, Single, Single, Single) method of the CanvasShapes collection.

The properties of the TableBackground object return objects that represent various aspects of the formatting associated with a table.

Examples

The following example shows how to get a TableBackground object and set two of its properties.

Public Sub TableBackground_Example()



    Dim pptShape As PowerPoint.Shape

    Dim pptTable As PowerPoint.Table

    Dim pptTableBackground As PowerPoint.TableBackground

    Dim pptFillFormat As PowerPoint.FillFormat

    

    Set pptShape = ActivePresentation.Slides(2).Shapes.AddTable(3, 3)

    Set pptTable = pptShape.Table

    Set pptTableBackground = pptTable.Background

    Set pptFillFormat = pptTableBackground.Fill

    

    ' Add a patterned fill to the table background

    pptFillFormat.Patterned (msoPatternSmallGrid)

    

    ' Add a shadow to the table background

    pptTableBackground.Shadow.Visible = msoTrue

    

End Sub

See Also

Reference

TableBackground Members

Microsoft.Office.Interop.PowerPoint Namespace