Skip to main content

Function: answerChoice()

function answerChoice(
context,
siteUrl,
activityId,
optionIds
): Promise<{
changed: string;
choice: Choice;
}>;

Defined in: areas/surveys/choice.ts:110

Answers a choice with one option (several where it allows them) by id, as "Save my choice" does; returns the choice afterwards.

Parameters​

ParameterType
contextBrowserContext
siteUrlstring
activityIdnumber
optionIdsnumber[]

Returns​

Promise<{ changed: string; choice: Choice; }>