Help with DHIS 2 functions

Hi everyone,

Can anyone give me guidance on which DHIS 2 function I can use to create a program rule for limiting the number of times a program stage is repeated or to hide program stage after it has been filled a number of times.

e.g, I want to hide a program stage after a variable (data element) in that stage has been filled 5 times in a program.

I appreciate any help on figuring out what the right path is.

Looks like this might have had some conversation here: Any possibility to limit a repeatable program stage? perhaps you can reach out to the involved parties?

Hi @Matthew_Boddie,

I have created program rules following the instructions in the post, but what happens is that the program stage is not hidden after the data element has been filled five times. I have configured a program action to display a message when number 5 is attained and it works.

What can I do to prevent the data clerk from adding more stages as they are supposed to be hidden? I would like to always show a message like: You can’t add any more events and not allowing the data clerk to move on.

Your feedback is welcome.

@hernandezmachava that definitely makes sense to me. I’m not well versed in the side of DHIS2 which you’re working in, so would have to pass to someone more experienced. I was hoping the people in the post that I linked might have had a solution that perhaps they didn’t fully communicate, and which you might be able to hear about. Sorry I can’t be of more help!