Delete Effects from an Interactive Sequence Introduction
Aspose.Slides Cloud API allows you to read, add, and modify animations in PowerPoint presentations. You can also delete effects from interactive animation sequences on special slides (Master, Layout, or Notes) in presentations using the following method.
DeleteSpecialSlideAnimationInteractiveSequenceEffect
API
Type
Description
Resource
/slides/{name}/slides/{slideIndex}/{slideType}/animation/interactiveSequences/{sequenceIndex}/{effectIndex}
DELETE
Deletes an effect from an interactive animation sequence on a special slide in a presentation saved in a storage.
DeleteSpecialSlideAnimationInteractiveSequenceEffect
Request Parameters
Name
Type
Location
Required
Description
name
string
path
true
The name of a presentation file.
slideIndex
integer
path
true
The 1-based index of a regular slide.
slideType
SpecialSlideType
path
true
The type of a special slide.
sequenceIndex
integer
path
true
The 1-based index of an interactive sequence.
effectIndex
integer
path
true
The 1-based index of an effect to be deleted.
password
string
header
false
The password to open the presentation.
folder
string
query
false
The path to the folder containing the presentation file.
storage
string
query
false
The name of the storage contaning the folder.
Example
The document MyPresentation.pptx saved in the default storage contains one interactive animation sequence with two effects on the Layout of the first slide. Delete the second effect.
cURL Solution
Request
Get an Access Token
curl POST "https://api.aspose.cloud/connect/token" \
-d "grant_type=client_credentials&client_id=MyClientId&client_secret=MyClientSecret" \
-H "Content-Type: application/x-www-form-urlencoded"
Delete the Effect
curl -X DELETE "https://api.aspose.cloud/v3.0/slides/MyPresentation.pptx/slides/1/LayoutSlide/animation/interactiveSequences/1/2" \
-H "authorization: Bearer MyAccessToken"
Response
Response Example
{
"mainSequence" : [],
"interactiveSequences" : [
{
"effects" : [
{
"type" : "Fade" ,
"subtype" : "None" ,
"presetClassType" : "Entrance" ,
"shapeIndex" : 3 ,
"triggerType" : "WithPrevious" ,
"duration" : 0.5 ,
"triggerDelayTime" : 0.0
}
],
"triggerShapeIndex" : 2
}
],
"selfUri" : {
"href" : "https://api.aspose.cloud/v3.0/slides/MyPresentation.pptx/layoutSlides/1/animation" ,
"relation" : "self"
}
}
SDK Solutions
C#
using System ;
using Aspose.Slides.Cloud.Sdk ;
using Aspose.Slides.Cloud.Sdk.Model ;
class Application
{
static void Main ( string [] args )
{
SlidesApi slidesApi = new SlidesApi ( "MyClientId" , "MyClientSecret" );
string fileName = "MyPresentation.pptx" ;
int slideIndex = 1 ;
SpecialSlideType slideType = SpecialSlideType . LayoutSlide ;
int sequenceIndex = 1 ;
int effectIndex = 2 ;
SlideAnimation slideAnimation = slidesApi . DeleteSpecialSlideAnimationInteractiveSequenceEffect ( fileName , slideIndex , slideType , sequenceIndex , effectIndex );
int effectCount = slideAnimation . InteractiveSequences [ sequenceIndex - 1 ]. Effects . Count ;
Console . WriteLine ( "Effect count: " + effectCount ); // 1
}
}
Java
import com.aspose.slides.ApiException ;
import com.aspose.slides.api.SlidesApi ;
import com.aspose.slides.model.SpecialSlideType ;
import com.aspose.slides.model.SlideAnimation ;
public class Application {
public static void main ( String [] args ) throws ApiException {
SlidesApi slidesApi = new SlidesApi ( "MyClientId" , "MyClientSecret" );
String fileName = "MyPresentation.pptx" ;
int slideIndex = 1 ;
SpecialSlideType slideType = SpecialSlideType . LAYOUTSLIDE ;
int sequenceIndex = 1 ;
int effectIndex = 2 ;
SlideAnimation slideAnimation = slidesApi . deleteSpecialSlideAnimationInteractiveSequenceEffect ( fileName , slideIndex , slideType , sequenceIndex , effectIndex , null , null , null );
int effectCount = slideAnimation . getInteractiveSequences (). get ( sequenceIndex - 1 ). getEffects (). size ();
System . out . println ( "Effect count: " + effectCount ); // 1
}
}
PHP
use Aspose\Slides\Cloud\Sdk\Api\Configuration ;
use Aspose\Slides\Cloud\Sdk\Api\SlidesApi ;
use Aspose\Slides\Cloud\Sdk\Model\SpecialSlideType ;
$configuration = new Configuration ();
$configuration -> setAppSid ( "MyClientId" );
$configuration -> setAppKey ( "MyClientSecret" );
$slidesApi = new SlidesApi ( null , $configuration );
$fileName = "MyPresentation.pptx" ;
$slideIndex = 1 ;
$slideType = SpecialSlideType :: LAYOUT_SLIDE ;
$sequenceIndex = 1 ;
$effectIndex = 2 ;
$slideAnimation = $slidesApi -> deleteSpecialSlideAnimationInteractiveSequenceEffect ( $fileName , $slideIndex , $slideType , $sequenceIndex , $effectIndex );
$effectCount = count ( $slideAnimation -> getInteractiveSequences ()[ $sequenceIndex - 1 ] -> getEffects ());
echo "Effect count: " , $effectCount ; // 1
Ruby
require "aspose_slides_cloud"
include AsposeSlidesCloud
configuration = Configuration . new
configuration . app_sid = "MyClientId"
configuration . app_key = "MyClientSecret"
slides_api = SlidesApi . new ( configuration )
file_name = "MyPresentation.pptx"
slide_index = 1
slide_type = SpecialSlideType :: LAYOUT_SLIDE
sequence_index = 1
effect_index = 2
slide_animation = slides_api . delete_special_slide_animation_interactive_sequence_effect ( file_name , slide_index , slide_type , sequence_index , effect_index )
effect_count = slide_animation . interactive_sequences [ sequence_index - 1 ]. effects . length ()
print "Effect count: " , effect_count # 1
Python
from asposeslidescloud.apis import SlidesApi
from asposeslidescloud.models import SpecialSlideType
slides_api = SlidesApi ( None , "MyClientId" , "MyClientSecret" )
file_name = "MyPresentation.pptx"
slide_index = 1
slide_type = SpecialSlideType . LAYOUTSLIDE
sequence_index = 1
effect_index = 2
slide_animation = slides_api . delete_special_slide_animation_interactive_sequence_effect ( file_name , slide_index , slide_type , sequence_index , effect_index )
effect_count = len ( slide_animation . interactive_sequences [ sequence_index - 1 ] . effects )
print ( "Effect count:" , effect_count ) # 1
Node.js
const cloudSdk = require ( "asposeslidescloud" );
const slidesApi = new cloudSdk . SlidesApi ( "MyClientId" , "MyClientSecret" );
fileName = "MyPresentation.pptx" ;
slideIndex = 1 ;
slideType = cloudSdk . SpecialSlideType . LayoutSlide ;
sequenceIndex = 1 ;
effectIndex = 2 ;
slidesApi . deleteSpecialSlideAnimationInteractiveSequenceEffect ( fileName , slideIndex , slideType , sequenceIndex , effectIndex ). then ( slideAnimation => {
effectCount = slideAnimation . body . interactiveSequences [ sequenceIndex - 1 ]. effects . length ;
console . log ( "Effect count:" , effectCount ); // 1
});
C++
#include "asposeslidescloud/api/SlidesApi.h"
using namespace asposeslidescloud :: api ;
int main ()
{
std :: shared_ptr < SlidesApi > slidesApi = std :: make_shared < SlidesApi > ( L "MyClientId" , L "MyClientSecret" );
const wchar_t * fileName = L "MyPresentation.pptx" ;
int slideIndex = 1 ;
const wchar_t * slideType = L "LayoutSlide" ;
int sequenceIndex = 1 ;
int effectIndex = 2 ;
std :: shared_ptr < SlideAnimation > slideAnimation = slidesApi -> deleteSpecialSlideAnimationInteractiveSequenceEffect ( fileName , slideIndex , slideType , sequenceIndex , effectIndex ). get ();
int effectCount = slideAnimation -> getInteractiveSequences ()[ sequenceIndex - 1 ] -> getEffects (). size ();
std :: wcout << L "Effect count: " << effectCount ; // 1
}
Perl
use AsposeSlidesCloud::Configuration ;
use AsposeSlidesCloud::SlidesApi ;
my $config = AsposeSlidesCloud::Configuration -> new ();
$config -> { app_sid } = "MyClientId" ;
$config -> { app_key } = "MyClientSecret" ;
my $slides_api = AsposeSlidesCloud::SlidesApi -> new ( config => $config );
my $file_name = "MyPresentation.pptx" ;
my $slide_index = 1 ;
my $slide_type = "LayoutSlide" ;
my $sequence_index = 1 ;
my $effect_index = 2 ;
my $slide_animation = $slides_api -> delete_special_slide_animation_interactive_sequence_effect (
name => $file_name , slide_index => $slide_index , slide_type => $slide_type , sequence_index => $sequence_index , effect_index => $effect_index );
my $effect_count = @ { $slide_animation -> { interactive_sequences }[ $sequence_index - 1 ] -> { effects }};
print ( "Effect count: " , $effect_count ); # 1
Swift
Go
import (
"fmt"
asposeslidescloud "github.com/aspose-slides-cloud/aspose-slides-cloud-go/v24"
)
func main () {
configuration := asposeslidescloud . NewConfiguration ()
configuration . AppSid = "MyClientId"
configuration . AppKey = "MyClientSecret"
slidesApi := asposeslidescloud . NewAPIClient ( configuration ). SlidesApi
fileName := "MyPresentation.pptx"
var slideIndex int32 = 1
slideType := string ( asposeslidescloud . SpecialSlideType_LayoutSlide )
var sequenceIndex int32 = 1
var effectIndex int32 = 2
slideAnimation , _ , _ := slidesApi . DeleteSpecialSlideAnimationInteractiveSequenceEffect ( fileName , slideIndex , slideType , sequenceIndex , effectIndex , "" , "" , "" )
effectCount := len ( slideAnimation . GetInteractiveSequences ()[ sequenceIndex - 1 ]. GetEffects ())
fmt . Println ( "Effect count:" , effectCount ) // 1
}
SDKs
Check Available SDKs to learn how to add an SDK to your project.