Please enable JavaScript to view this site.

ESL Documentation

The ancestry function lets you find and use the string associated with the ancestry of the object that stimulated the response, or the object and its ancestry containing the item that stimulated the response.

 

In the example below, after the user selects the object Done, the object's immediate parent is deleted, which causes the object Done to be deleted also.

 

response to Done

    delete ancestry

 

Be careful not to confuse the ancestry function with the ancestry of function. The ancestry of function is an object inquiry, returning the string associated with the object whose name is specified as the argument to the function. You cannot use the ancestry of function with items.

 

For information on the use of the ancestry function with classes of objects, see Using Built-in Functions with Classes.