CTestAttempt::AttemptFinished
bool CTestAttempt::AttemptFinished( int ATTEMPT_ID );
The AttemptFinished method moves an attempt to the Complete status and counts the score.
Parameters
Parameter | Description |
---|---|
ATTEMPT_ID | The attempt ID. |
Return Values
The method returns true on success, or false otherwise.
See Also
Example
if (CModule::IncludeModule("learning")) { $ATTEMPT_ID = 23; $oTestAttempt = new CTestAttempt; $success = $oTestAttempt->AttemptFinished($ATTEMPT_ID); if ($success) echo "Attempt has been finished"; else echo "Error!"; }
© «Bitrix24», 2001-2024