Contains

MathParagraph.Contains méthode

Détermine si la collection contient une valeur spécifique.

public bool Contains(IMathBlock mathBlock)
ParamètreTypeDescription
mathBlockIMathBlockL’objet à localiser dans la collection.

Valeur de retour

true si mathBlock est trouvé dans la collection ; sinon, false.

Exemples

Exemple:

[C#]
IAutoShape shape = slide.Shapes.AddMathShape(x, y, width, height);
IMathParagraph mathParagraph = (shape.TextFrame.Paragraphs[0].Portions[0] as MathPortion).MathParagraph;
IMathBlock block = new MathBlock(new MathematicalText("y"));
mathParagraph.Add(block);
bool contains = mathParagraph.Contains(block);

Voir aussi