launchByObjectNumber (webtop script and webtop tray applets)

Syntax

string launchByObjectNumber(int objectNumber)

Description

Activates the specified link, just as if a user had clicked it on their webtop.

objectNumber specifies a link on the webtop. The value 0 specifies the first link on the webtop, 1 the second and so on.

Note You can use the applet's ObjectNumber parameter to change the number from which links are numbered (default is zero).

This method returns OK if Tarantella successfully launches the application (or displays the document) represented by the link, and Error otherwise.

This method can be used with either the webtop script applet or the webtop tray applet.

Examples

<SCRIPT LANGUAGE="JavaScript">
 
function launchFirstLink() {
   document.applets["Tarantella Webtop"].launchByObjectNumber(0);
}
 
</SCRIPT>
 
<FORM>
   <INPUT TYPE=button VALUE="Activate First Link" onclick="launchFirstLink()">
</FORM>

This example adds a button beneath the links on users' webtops. When a user clicks this button, Tarantella activates the first link on their webtop.

Add the code to the HTML document containing the webtop tray applet (left.html, in the sco/tta/standard webtop theme), after the TTAAPPLET declaration.

Note This example assumes you are using the sco/tta/standard webtop theme. If you're using another theme, with different frame names and layouts, or different applet names, you'll need to modify the line that invokes the launchByObjectNumber method to access the webtop tray applet used by your new theme.

Related topics
  • Webtop script applet
  • Webtop tray applet
  • launchByObjectName (webtop script and webtop tray applets)