bool CTestAttempt::AttemptFinished( int ATTEMPT_ID );
The AttemptFinished method moves an attempt to the Complete status and counts the score.
Parameter | Description |
---|---|
ATTEMPT_ID | The attempt ID. |
The method returns true on success, or false otherwise.
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!"; }
© 2001-2007 Bitrix | Bitrix Site Manager - Content Management & Portal Solutions |