GetEffective

TableFormat.GetEffective Methode

Erhält effektive Tabellenformatierungs-Eigenschaften mit Vererbung und angewendeten Tabellenstilen.

public ITableFormatEffectiveData GetEffective()

Rückgabewert

Ein ITableFormatEffectiveData.

Beispiele

Dieses Beispiel demonstriert, wie man das effektive Füllformat für verschiedene Teile der Tabellenlogik erhält. Bitte beachten Sie, dass die Zellenformatierung immer eine höhere Priorität hat als die Zeilenformatierung, die Zeilen eine höhere Priorität als die Spalten hat und die Spalten eine höhere Priorität als die gesamte Tabelle haben. Daher werden letztendlich die Eigenschaften von CellFormatEffectiveData verwendet, um die Tabelle zu zeichnen. Der folgende Code ist nur ein Beispiel für die API.

[C#]
using (Presentation pres = new Presentation(@"MyPresentation.pptx"))
{
    ITable tbl = pres.Slides[0].Shapes[0] as Table;
    IFillFormatEffectiveData tableFillFormatEffective = tbl.TableFormat.GetEffective().FillFormat;
    IFillFormatEffectiveData rowFillFormatEffective = tbl.Rows[0].RowFormat.GetEffective().FillFormat;
    IFillFormatEffectiveData columnFillFormatEffective = tbl.Columns[0].ColumnFormat.GetEffective().FillFormat;
    IFillFormatEffectiveData cellFillFormatEffective = tbl[0, 0].CellFormat.GetEffective().FillFormat;
    /* Ausgabe und Vergleich */
}

Siehe Auch