Navigation Menu

Click the "+" to see inside a chapter or use the search to the right.

.

Skip to end of metadata
Go to start of metadata

A custom Groovy Script is a custom Java code to alter the runtime behavior of an exam. It is useful to achieve what out-of-the-box Groovy Scripts fail to achieve. We will see how a custom Groovy Script can be specified.

Icon

A DT Item Bank must exist in the project to use this feature.

Steps to access the custom Groovy Script feature

  1. Select the DT Item Bank from the Home screen.
  2. Select the Develop Questions → Write Item menu, and click Write Question. Select any Question Type from the drop-down. The most common type is a Display-Type item.
  3. Click the Question Stem box for the Rich Text editor toolbar to appear and select the Tools → Source code menu. The HTML Source Editor pop-up opens.

  4. Inside HTML Source code editor, we need to specify the custom Groovy Script manually inside “[[Groovy:]]” placeholder as shown below.
  5. Click the OK button to insert the custom Groovy Script into the Rich Text editor.
  6. Save the item by clicking Submit, and then again Submit from the Confirm Submit pop-up window.
  7. Click the Home link and select a Standard Item Bank and select a Project.
  8. Select the Create Exam Form View Exam menu to view the list of available exam forms.
  9. Select an exam form check box and click Build QTI Package button at the bottom. The Delivery Configuration Tool page opens.

  10. Right-click the ExamForm node and select Section from the pop-up menu.
  11. Select Section-Default from the drop-down list in the Add Template pop-up window and click Add. This adds a default Section node under the ExamForm node.
  12. Click the Section node created in the previous step and click the Add Item button below Section in the right pane. This launches a pop-up window to search for items from the DT Item Bank.
  13. Retrieve the item you had saved with the Custom Groovy in step 6, select it via corresponding check box, and click Add Contents button.
  14. The item is added to the Section. Click Save.
  15. Export QTI Package with the Export button.



  • No labels