Share via


Cell.Selected Property

Returns True if the specified table cell is selected. Read-only.

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

Syntax

'Declaration
ReadOnly Property Selected As Boolean
    Get
'Usage
Dim instance As Cell
Dim value As Boolean

value = instance.Selected
bool Selected { get; }

Property Value

Type: System.Boolean
Boolean

Examples

This example puts a border around the first cell in the specified table if the cell is selected.

Sub IsCellSelected()

    Dim celSelected As Cell

    Set celSelected = ActivePresentation.Slides(1).Shapes(1) _

        .Table.Columns(1).Cells(1)

    If celSelected.SelectedThen

        With celSelected

            .Borders(ppBorderTop).DashStyle = msoLineRoundDot

            .Borders(ppBorderBottom).DashStyle = msoLineRoundDot

            .Borders(ppBorderLeft).DashStyle = msoLineRoundDot

            .Borders(ppBorderRight).DashStyle = msoLineRoundDot

        End With

    End If

End Sub

See Also

Reference

Cell Interface

Cell Members

Microsoft.Office.Interop.PowerPoint Namespace