Hi Arnaud,

You cannot have conditional visibility on a single widget (unless you do it yourself with Python), but you can have conditional visibility on a group based on an expression that can reference the value of another field.

Create a "Group" container in the drag and drop form with the "green plus" icon. Then click on the group, activate the "Control visibility by Expression" and enter your expression. The expression needs to return 1 for visible or 0 for not visible.

Hope this helps,

Andreas

On 2021-06-11 07:01, Arnaud Vandecasteele wrote:

Hi,

When creating a form by drag and drop fields, all fields are displayed unless you choose the hidden widget or you remove them from the field.

But how to hide or show a form field depending on whether the user has completed a previous field?

Thanks,

Arnaud

--

--------------------------------------------------------------------
Arnaud Vandecasteele

_______________________________________________
Qgis-user mailing list
[email protected]
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
_______________________________________________
Qgis-user mailing list
[email protected]
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

Reply via email to