Note: You are currently viewing documentation for Moodle 2.8. Up-to-date documentation for the latest stable version of Moodle may be available here: Conditional activities.

Conditional activities

From MoodleDocs

Template:Moodle 2.0 Conditional activities is a new feature in Moodle 2.0 onwards, which enables teachers to restrict the availability of any activity according to certain conditions such as dates, grade obtained, or activity completion.

Please see the following demonstration videos:


Enabling the use of conditional activities

Restrict availability and activity completion settings on the edit activity page

To use conditional activities, the feature must be enabled by an administrator by checking the enableavailability box in Administration > Advanced features. A Restrict availability section will appear for teachers on the edit activity page.

Enabling the use of completion tracking

To use completion tracking, the feature must be enabled by an administrator by checking the enablecompletion box in Administration > Advanced features. An Activity completion section will appear for teachers on the edit activity page.

Tricks and techniques

With a bit of lateral thinking, you can achieve some interesting results beyond the most obvious uses of the system.

Project allocation

Imagine that you let students choose one of two projects. Each project has its own activities (a forum for all the people doing that project, resources with information about the project, etc). You want it to hide all the activities that a student isn't doing.

This can already be achieved in Moodle using the Groupings system. However, conditional activities gives another way to set this up which might be preferable in some cases. Here's how:

  1. Create two forums called 'Frog project sign-up forum' and 'Zombie project sign-up forum'.
  2. Set both forums to be automatically marked complete once the user makes 1 post.
  3. Set each forum to be conditionally available only if the other forum is NOT complete.
  4. Create other activities for the frog and zombie projects. For each Frog activity, set it to be conditionally available only if the Frog sign-up forum is marked complete. For each Zombie activity, set it to be conditionally available only if the Zombie sign-up forum is marked complete.

When a student first visits the site, they see the frog and zombie sign-up forums and none of the project activities. As soon as they post in one of the forums, the other forum will disappear, and all the activities for their preferred project will appear. (If they want to change their mind, they can delete their forum post so that it isn't marked complete any more, and it'll be back to square one.)

Discussion: Should you really use conditional activities?

Conditional activities are a way for you to force your students to do things in a certain order. Is that really what you want?

It is certainly good course design to make it clear to your students what they are expected to do next, to give good guidance. But do you need to use force? Might it not be better to leave students in control of their own learning and just use labels and layout, rather than locks and keys to suggest the best path?

On the other hand, you may have to design a certified training course that requires approval from unenlightened government regulators. Conditional activities will assure them that the trainees have been exposed to everything in the course, in a fixed order, and that the trainees must meet certain quantifiable standards from time to time before being allowed to proceed in the course. Correct use and explanation of conditional activities may ensure validation of your course.

So the answer will depend on your particular circumstances, but it is worth taking a moment to reflect upon the degree to which conditional activities are appropriate for your course.

See also