menu

Document Processing

Interface IEffect - FileFormats API Reference | Syncfusion

    Show / Hide Table of Contents

    Interface IEffect

    Represents the effect.

    Namespace: Syncfusion.Presentation
    Assembly: Syncfusion.Presentation.Base.dll
    Syntax
    public interface IEffect

    Properties

    Behaviors

    Get the list of behaviors in particular effect

    Declaration
    IBehaviors Behaviors { get; }
    Property Value
    Type
    IBehaviors
    Examples
    // Create a new presentation.
    IPresentation ppDoc = Presentation.Create();
    // Add a slide to the presentation.
    ISlide slide = ppDoc.Slides.Add(SlideLayoutType.Blank);
    // Add shape on the slide
    IShape shape = slide.Shapes.AddShape(AutoShapeType.Diamond, 150, 150, 250, 150);
    // Add animation effect on the slide with shape
    IEffect effect = ppDoc.Slides[0].Timeline.MainSequence.AddEffect(shape, EffectType.Bounce, EffectSubtype.None, EffectTriggerType.OnClick);
    // Get the behaviors list from the effect
    IBehaviors effectBehaviors = effect.Behaviors;
    // Save the presentation file
    ppDoc.Save("Sample.pptx");
    // Close the presentation file
    ppDoc.Close();
    'Create a new presentation
    Dim ppDoc As IPresentation = Presentation.Create()
    'Add a slide to the presentation.
    Dim slide As ISlide = ppDoc.Slides.Add(SlideLayoutType.Blank)
    'Add shape on the slide
    Dim shape As IShape = slide.Shapes.AddShape(AutoShapeType.Diamond, 150, 150, 250, 150)
    'Add animation effect on the slide with shape
    Dim effect As IEffect = ppDoc.Slides(0).TimeLine.MainSequence.AddEffect(shape, EffectType.Bounce, EffectSubtype.None, EffectTriggerType.OnClick)
    'Get the behaviors list from the effect
    Dim effectBehaviors As IBehaviors = effect.Behaviors
    'Save the presentation file
    ppDoc.Save("Sample.pptx")
    'Close the presentation file
    ppDoc.Close()

    BuildType

    Get the build type value of text animation

    Declaration
    BuildType BuildType { get; }
    Property Value
    Type
    BuildType
    Examples
    // Create a new presentation.
    IPresentation ppDoc = Presentation.Create();
    // Add a slide to the presentation.
    ISlide slide = ppDoc.Slides.Add(SlideLayoutType.Blank);
    // Add shape on the slide
    IShape shape = slide.Shapes.AddShape(AutoShapeType.Diamond, 150, 150, 250, 150);
    // Add animation effect on the slide with shape
    IEffect effect = ppDoc.Slides[0].Timeline.MainSequence.AddEffect(shape, EffectType.Bounce, EffectSubtype.None, EffectTriggerType.OnClick);
    // Get the build type from the effect
    BuildType effectBuildType = effect.BuildType;
    // Save the presentation file
    ppDoc.Save("Sample.pptx");
    // Close the presentation file
    ppDoc.Close();
    'Create a new presentation
    Dim ppDoc As IPresentation = Presentation.Create()
    'Add a slide to the presentation.
    Dim slide As ISlide = ppDoc.Slides.Add(SlideLayoutType.Blank)
    'Add shape on the slide
    Dim shape As IShape = slide.Shapes.AddShape(AutoShapeType.Diamond, 150, 150, 250, 150)
    'Add animation effect on the slide with shape
    Dim effect As IEffect = ppDoc.Slides(0).TimeLine.MainSequence.AddEffect(shape, EffectType.Bounce, EffectSubtype.None, EffectTriggerType.OnClick)
    'Get the build type from the effect
    Dim effectBuildType As BuildType = effect.BuildType
    'Save the presentation file
    ppDoc.Save("Sample.pptx")
    'Close the presentation file
    ppDoc.Close()

    PresetClassType

    Get the preset class type of effect

    Declaration
    EffectPresetClassType PresetClassType { get; set; }
    Property Value
    Type
    EffectPresetClassType
    Examples
    // Create a new presentation.
    IPresentation ppDoc = Presentation.Create();
    // Add a slide to the presentation.
    ISlide slide = ppDoc.Slides.Add(SlideLayoutType.Blank);
    // Add shape on the slide
    IShape shape = slide.Shapes.AddShape(AutoShapeType.Diamond, 150, 150, 250, 150);
    // Add animation effect on the slide with shape
    IEffect effect = ppDoc.Slides[0].Timeline.MainSequence.AddEffect(shape, EffectType.Bounce, EffectSubtype.None, EffectTriggerType.OnClick);
    // Get the preset class type from the effect
     EffectPresetClassType effectPresetClass = effect.PresetClassType;
    // Save the presentation file
    ppDoc.Save("Sample.pptx");
    // Close the presentation file
    ppDoc.Close();
    'Create a new presentation
    Dim ppDoc As IPresentation = Presentation.Create()
    'Add a slide to the presentation.
    Dim slide As ISlide = ppDoc.Slides.Add(SlideLayoutType.Blank)
    'Add shape on the slide
    Dim shape As IShape = slide.Shapes.AddShape(AutoShapeType.Diamond, 150, 150, 250, 150)
    'Add animation effect on the slide with shape
    Dim effect As IEffect = ppDoc.Slides(0).TimeLine.MainSequence.AddEffect(shape, EffectType.Bounce, EffectSubtype.None, EffectTriggerType.OnClick)
    'Get the effect preset class type from the effect
     Dim effectPresetClass As EffectPresetClassType = effect.PresetClassType
    'Save the presentation file
    ppDoc.Save("Sample.pptx")
    'Close the presentation file
    ppDoc.Close()

    Sequence

    Get the main sequences list of animations

    Declaration
    ISequence Sequence { get; }
    Property Value
    Type
    ISequence
    Examples
    // Create a new presentation.
    IPresentation ppDoc = Presentation.Create();
    // Add a slide to the presentation.
    ISlide slide = ppDoc.Slides.Add(SlideLayoutType.Blank);
    // Add shape on the slide
    IShape shape = slide.Shapes.AddShape(AutoShapeType.Diamond, 150, 150, 250, 150);
    // Add animation effect on the slide with shape
    IEffect effect = ppDoc.Slides[0].Timeline.MainSequence.AddEffect(shape, EffectType.Bounce, EffectSubtype.None, EffectTriggerType.OnClick);
    // Get the sequences from the effect
    ISequence effectSequence = effect.Sequence;
    // Save the presentation file
    ppDoc.Save("Sample.pptx");
    // Close the presentation file
    ppDoc.Close();
    'Create a new presentation
    Dim ppDoc As IPresentation = Presentation.Create()
    'Add a slide to the presentation.
    Dim slide As ISlide = ppDoc.Slides.Add(SlideLayoutType.Blank)
    'Add shape on the slide
    Dim shape As IShape = slide.Shapes.AddShape(AutoShapeType.Diamond, 150, 150, 250, 150)
    'Add animation effect on the slide with shape
    Dim effect As IEffect = ppDoc.Slides(0).TimeLine.MainSequence.AddEffect(shape, EffectType.Bounce, EffectSubtype.None, EffectTriggerType.OnClick)
    'Get the sequences from the effect
    Dim effectSequence As ISequence = effect.Sequence
    'Save the presentation file
    ppDoc.Save("Sample.pptx")
    'Close the presentation file
    ppDoc.Close()

    Subtype

    Get the sub type value of effect

    Declaration
    EffectSubtype Subtype { get; set; }
    Property Value
    Type
    EffectSubtype
    Examples
    // Create a new presentation.
    IPresentation ppDoc = Presentation.Create();
    // Add a slide to the presentation.
    ISlide slide = ppDoc.Slides.Add(SlideLayoutType.Blank);
    // Add shape on the slide
    IShape shape = slide.Shapes.AddShape(AutoShapeType.Diamond, 150, 150, 250, 150);
    // Add animation effect on the slide with shape
    IEffect effect = ppDoc.Slides[0].Timeline.MainSequence.AddEffect(shape, EffectType.Bounce, EffectSubtype.None, EffectTriggerType.OnClick);
    // Get the subtype from the effect
    EffectSubtype effectSubType = effect.Subtype;
    // Save the presentation file
    ppDoc.Save("Sample.pptx");
    // Close the presentation file
    ppDoc.Close();
    'Create a new presentation
    Dim ppDoc As IPresentation = Presentation.Create()
    'Add a slide to the presentation.
    Dim slide As ISlide = ppDoc.Slides.Add(SlideLayoutType.Blank)
    'Add shape on the slide
    Dim shape As IShape = slide.Shapes.AddShape(AutoShapeType.Diamond, 150, 150, 250, 150)
    'Add animation effect on the slide with shape
    Dim effect As IEffect = ppDoc.Slides(0).TimeLine.MainSequence.AddEffect(shape, EffectType.Bounce, EffectSubtype.None, EffectTriggerType.OnClick)
    'Get the subtype from the effect
    Dim effectSubType As EffectSubtype = effect.Subtype
    'Save the presentation file
    ppDoc.Save("Sample.pptx")
    'Close the presentation file
    ppDoc.Close()

    Timing

    Get the timing properties values of effect

    Declaration
    ITiming Timing { get; }
    Property Value
    Type
    ITiming
    Examples
    // Create a new presentation.
    IPresentation ppDoc = Presentation.Create();
    // Add a slide to the presentation.
    ISlide slide = ppDoc.Slides.Add(SlideLayoutType.Blank);
    // Add shape on the slide
    IShape shape = slide.Shapes.AddShape(AutoShapeType.Diamond, 150, 150, 250, 150);
    // Add animation effect on the slide with shape
    IEffect effect = ppDoc.Slides[0].Timeline.MainSequence.AddEffect(shape, EffectType.Bounce, EffectSubtype.None, EffectTriggerType.OnClick);
    // Get the timing list from the effect
    ITiming effectTiming = effect.Timing;
    // Save the presentation file
    ppDoc.Save("Sample.pptx");
    // Close the presentation file
    ppDoc.Close();
    'Create a new presentation
    Dim ppDoc As IPresentation = Presentation.Create()
    'Add a slide to the presentation.
    Dim slide As ISlide = ppDoc.Slides.Add(SlideLayoutType.Blank)
    'Add shape on the slide
    Dim shape As IShape = slide.Shapes.AddShape(AutoShapeType.Diamond, 150, 150, 250, 150)
    'Add animation effect on the slide with shape
    Dim effect As IEffect = ppDoc.Slides(0).TimeLine.MainSequence.AddEffect(shape, EffectType.Bounce, EffectSubtype.None, EffectTriggerType.OnClick)
    'Get the timing list from the effect
    Dim effectTiming As ITiming = effect.Timing
    'Save the presentation file
    ppDoc.Save("Sample.pptx")
    'Close the presentation file
    ppDoc.Close()

    Type

    Get the type of effect

    Declaration
    EffectType Type { get; set; }
    Property Value
    Type
    EffectType
    Examples
    // Create a new presentation.
    IPresentation ppDoc = Presentation.Create();
    // Add a slide to the presentation.
    ISlide slide = ppDoc.Slides.Add(SlideLayoutType.Blank);
    // Add shape on the slide
    IShape shape = slide.Shapes.AddShape(AutoShapeType.Diamond, 150, 150, 250, 150);
    // Add animation effect on the slide with shape
    IEffect effect = ppDoc.Slides[0].Timeline.MainSequence.AddEffect(shape, EffectType.Bounce, EffectSubtype.None, EffectTriggerType.OnClick);
    // Get effect type
    EffectType effectType = effect.Type;
    // Save the presentation file
    ppDoc.Save("Sample.pptx");
    // Close the presentation file
    ppDoc.Close();
    'Create a new presentation
    Dim ppDoc As IPresentation = Presentation.Create()
    'Add a slide to the presentation.
    Dim slide As ISlide = ppDoc.Slides.Add(SlideLayoutType.Blank)
    'Add shape on the slide
    Dim shape As IShape = slide.Shapes.AddShape(AutoShapeType.Diamond, 150, 150, 250, 150)
    'Add animation effect on the slide with shape
    Dim effect As IEffect = ppDoc.Slides(0).TimeLine.MainSequence.AddEffect(shape, EffectType.Bounce, EffectSubtype.None, EffectTriggerType.OnClick)
    'Get effect type
    Dim effectType As EffectType = effect.Type
    'Save the presentation file
    ppDoc.Save("Sample.pptx")
    'Close the presentation file
    ppDoc.Close()
    Back to top Generated by DocFX
    OSZAR »
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved
    OSZAR »