This topic describes the API operations that are related to presentation tags.
Tags
ActivePresentation.SlideShowWindow.View.Slide.Tags
Obtains all tags on the current slide of the active presentation.
Only JS-SDK V1.1.14 and later support this feature.
Syntax
expression.ActivePresentation.SlideShowWindow.View.Slide.Tagsexpression: an Application object.
Example
async function example() { await instance.ready(); const app = instance.Application; // Obtain the Presentation object. const presentation = await app.ActivePresentation; // Obtain all tags on the current slide. const view = await presentation.SlideShowWindow.View.Slide.Tags; }
Methods
ActivePresentation.SlideShowWindow.View.Slide.Tags.Item()
Obtains the specified tag.
Only JS-SDK V1.1.14 and later support this feature.
Syntax
expression.ActivePresentation.SlideShowWindow.View.Slide.Tags.Item(Index)expression: an Application object.
Parameters
Parameter
Type
Required
Description
Index
Number
Yes
The index number of the slide.
Example
async function example() { await instance.ready(); const app = instance.Application; // Obtain a tag. await app.ActivePresentation.SlideShowWindow.View.Slide.Tags.Item(1); }
ActivePresentation.SlideShowWindow.View.Slide.Tags.Add()
Adds a tag.
Only JS-SDK V1.1.14 and later support this feature.
Syntax
expression.ActivePresentation.SlideShowWindow.View.Slide.Tags.Add({Name,Value})expression: an Application object.
Parameters
Parameter
Type
Required
Description
Name
String
Yes
The name of the tag.
Value
String
Yes
The value of the tag.
Example
async function example() { await instance.ready(); const app = instance.Application; // Add a tag. await app.ActivePresentation.SlideShowWindow.View.Slide.Tags.Add({Name:'test',Value:'123'}); }
ActivePresentation.SlideShowWindow.View.Slide.Tags.Delete()
Deletes a tag.
Only JS-SDK V1.1.14 and later support this feature.
Syntax
expression.ActivePresentation.SlideShowWindow.View.Slide.Tags.Delete({Name})expression: an Application object.
Parameters
Parameter
Type
Required
Description
Name
String
Yes
The name of the tag.
Example
async function example() { await instance.ready(); const app = instance.Application; // Delete the specified tag. await app.ActivePresentation.SlideShowWindow.View.Slide.Tags.Delete({Name:'test'}); }
ActivePresentation.SlideShowWindow.View.Slide.Tags.Has()
Determines whether the specified tag exists.
Only JS-SDK V1.1.14 and later support this feature.
Syntax
expression.ActivePresentation.SlideShowWindow.View.Slide.Tags.Has({Name})expression: an Application object.
Parameters
Parameter
Type
Required
Description
Name
String
Yes
The name of the tag.
Example
async function example() { await instance.ready(); const app = instance.Application; // Determine whether the tag exists. await app.ActivePresentation.SlideShowWindow.View.Slide.Tags.Has({Name:'test'}); }
ActivePresentation.SlideShowWindow.View.Slide.Tags.Name()
Obtains the name of the specified tag.
Only JS-SDK V1.1.14 and later support this feature.
Syntax
expression.ActivePresentation.SlideShowWindow.View.Slide.Tags.Name({Index})expression: an Application object.
Parameters
Parameter
Type
Required
Description
Index
NumberYes
The index number of the current slide.
Example
async function example() { await instance.ready(); const app = instance.Application; // Obtain the name of the second tag on the current slide. const Name = await app.ActivePresentation.SlideShowWindow.View.Slide.Tags.Name({ Index: 2 }); }
ActivePresentation.SlideShowWindow.View.Slide.Tags.Value()
Obtains the value of the specified tag.
Only JS-SDK V1.1.14 and later support this feature.
Syntax
expression.ActivePresentation.SlideShowWindow.View.Slide.Tags.Value({Index})expression: an Application object.
Parameters
Parameter
Type
Required
Description
Index
NumberYes
The index number of the current slide.
Example
async function example() { await instance.ready(); const app = instance.Application; // Obtain the value of the second tag on the current slide. const Name = await app.ActivePresentation.SlideShowWindow.View.Slide.Tags.Value({ Index: 2 }); }
Properties
ActivePresentation.SlideShowWindow.View.Slide.Tags.Count
Counts the number of the tags on the current slide of the active presentation.
Only JS-SDK V1.1.14 and later support this feature.
Syntax
expression.ActivePresentation.SlideShowWindow.View.Slide.Tags.Countexpression: an Application object.
Example
async function example() { await instance.ready(); const app = instance.Application; // Obtain the Presentation object. const presentation = await app.ActivePresentation; // Obtain all tags on the current slide. const view = await presentation.SlideShowWindow.View.Slide.Tags; // Obtain the number of tags on the current slide. const count = await view.Count; console.log(count); }
ActivePresentation.SlideShowWindow.View.Slide.Tags.Parent
Obtains the parent object of the specified tag.
Only JS-SDK V1.1.14 and later support this feature.
Syntax
expression.ActivePresentation.SlideShowWindow.View.Slide.Tags.Parentexpression: an Application object.
Example
async function example() { await instance.ready(); const app = instance.Application; // Obtain the Presentation object. const presentation = await app.ActivePresentation; // Obtain all tags on the current slide. const view = await presentation.SlideShowWindow.View.Slide.Tags; // Obtain the parent object of the tags. const Parent = await view.Parent; console.log(Parent); }