Edit

Share via


Script Interface

Definition

Represents a block of HTML script in a Microsoft Word document, on a Microsoft Excel spreadsheet, or on a Microsoft PowerPoint slide.

public interface class Script : Microsoft::Office::Core::_IMsoDispObj
[System.Runtime.InteropServices.Guid("000C0341-0000-0000-C000-000000000046")]
public interface Script : Microsoft.Office.Core._IMsoDispObj
[<System.Runtime.InteropServices.Guid("000C0341-0000-0000-C000-000000000046")>]
type Script = interface
    interface _IMsoDispObj
Public Interface Script
Implements _IMsoDispObj
Attributes
Implements

Remarks

The Script object is a member of the Scripts collection.

Use Scripts.Item(index), where index is the name, ID, or index number of a script, to return a single Script object. Each Script object is identified by the Id property, which provides a convenient name you can use to access the script.

You can specify the scripting language used in the script by changing the Language property.

You can check the ___location of the script anchor shape within an HTML document by using the Location property.

You can check or set attributes added to the <SCRIPT> tag (with the exception of the LANGUAGE and ID attributes) by using the Extended property.

You can check or set the script text associated with a given script by using the ScriptText property.

Properties

Application

Returns an Application object that represents the container application for the object.

Creator

Returns a 32-bit integer that indicates the application in which the specified object was created.

Extended

Returns or sets attributes added to the <SCRIPT> tag, with the exception of the LANGUAGE and ID attributes.

Id

Returns or sets the ID of a Script object.

Language

Returns or sets the scripting language of the active script.

Location

Returns the ___location of the script anchor in the specified HTML document.

Parent

Returns the Parent object for the specified object.

ScriptText

Returns or sets the text contained in a block of script.

Shape

Returns a Shape object or InlineShape object, depending on the Microsoft Office host application.

Methods

Delete()

Deletes the specified object from the collection.

Applies to