Skip to main content


Type: function(objectsToSelect: array)
Returns: Promise<void>

Attempts to select matched objects, prompting missing information such as ticket types with with a dialog.

The parameter objectsToSelect must be an array of strings or an array of objects.

chart.trySelectObjects(['A-1', 'A-2']);
chart.trySelectObjects(['A-1', 'A-2'], () => console.log('selection successful'));
chart.trySelectObjects([{id: 'A-1', ticketType: 'adult'}]);
chart.trySelectObjects(['General Admission 1', 'General Admission 1']);
chart.trySelectObjects([{id: 'General Admission 1', ticketType: 'adult', amount: 3}]);

If a String is provided, the objects that match the provided IDs will be selected.

If an array of objects is passed, these objects should have the following structure:

id: String, (required)
ticketType: String (optional)
amount: Number (optional)

Note that the promise does not resolve to an array of selected objects. Use onObjectSelected for that.