All Products
Search
Document Center

Intelligent Media Management:Application

Last Updated:Mar 31, 2025

This topic describes the API operations that are related to the Application object of table documents.

Method

Application.Base10To26()

You can convert a base-10 number to a base-26 string of letters A to Z by using the Base10To26() method.

  • Syntax

    expression.Application.Base10To26()

    expression: the document type application object.

  • Example

    async function example() {
      await instance.ready();
    
      const app = instance.Application;
      
      // Convert a base-10 number to a base-26 string of letters A to Z.
      const word = await app.Base10To26(23);
      console.log(word);
    }

Application.Base26To10()

You can convert base-26 string of letters A to Z to a base-10 number by using the Base26To10() method.

  • Syntax

    expression.Application.Base26To10()

    expression: the document type application object.

  • Example

    async function example() {
      await instance.ready();
    
      const app = instance.Application;
      
      // Convert a base-26 string of letters A to Z to a base-10 number.
      const word = await app.Base10To26(23);
      console.log(word);
    }

For()

You can obtain the names of all worksheets by using the For() method.

  • Syntax

    expression.For(Start, End, Step, Handle)

    expression: the document type application object.

  • Parameters

    Property

    Type

    Required

    Description

    Start

    Number

    Yes

    The position of the sheet at the beginning of the table.

    End

    Number

    No

    The position of the sheet at the end of the table.

    Step

    Number

    No

    The number of steps of each traversal.

    Handle

    Number

    No

    Callback method

  • Example

    async function example() {
      await instance.ready();
      
      const app = instance.Application;
    
      // Obtain the names of all worksheets.
      const Names = [];
      await app.For(
        1,
        app.Sheets.Count,
        1,
        async (Index) => {
          Names.push(await app.Sheets.Item(Index).Name);
        },
      );
      console.log(Names);
    }

Property

Application.Selection

You can obtain a content object that is selected by using the Selection property.

Important

Only JS-SDK V1.1.10 and later support this feature.

  • Syntax

    expression.Application.Selection

    expression: the document type application object.

  • Example

    async function example() {
      await instance.ready();
    
      const app = instance.Application;
    
     // Obtain a content object that is selected.
      const Selection = await app.Selection;
      console.log(Selection);
    }

Application.Users

By using the Users property, you can obtain information about the users who are using online collaboration.

Important

Only JS-SDK V1.1.10 and later support this feature.

  • Syntax

    expression.Application.Users

    expression: the document type application object.

  • Example

    async function example() {
      await instance.ready();
    
      const app = instance.Application;
    
      // Obtain information about the users who are using online collaboration.
      const users = await app.Users;
      console.log(users);
    }