Conditional logic - Image picker

  • Profile Image
    improntapublicidadva
    Asked on October 29, 2020 at 09:18 AM

    I want to add some conditionals to an Object or Select Image Widget, but I can't make it work. How can I ask for the value or content because I couldn't do it so far.


    Thanks

  • Profile Image
    Jimmy_D
    Answered on October 29, 2020 at 09:44 AM

    Hi there!

    Can you elaborate further on what you would like to achieve? 

    I understand you could not apply the condition to an object, but I am not clear about what you would like to achieve with it. 


  • Profile Image
    improntapublicidadva
    Answered on October 29, 2020 at 10:39 AM

    Ok, I can try. I need that the customer can select an image, and then based on the selection I can make a condition that for example hide other widget, or if Image "A" is selected, then make a calculation on which A is 10 and B is 20.. Do I have to use code or how?

  • Profile Image
    improntapublicidadva
    Answered on October 29, 2020 at 10:43 AM

    It would be nice using Image Box or Image Selector.

  • Profile Image
    Gustavo_H
    Answered on October 29, 2020 at 12:44 PM

    Hi, @improntapublicidadva. How are you?


    There are several ways to achieve what you need. You should be able to set these conditions using whatever Image widget in your form. To show or hide fields based on what image the user will select, follow the guides below. The first guide will introduce you to everything you can do using conditions. The next two are respectively, for hiding fields based on user's answers and inserting calculation into a field.

    Complete guide 👉 how-to-show-or-hide-fields-base-on-user-s-answer

    Complete guide 👉 how-to-insert-text-or-calculation-into-a-field-using-conditional-logic


    Please, read these guides carefully, and you will be able to achieve your needs. I did a short example for you cloning your form. You can see it here.

    Clone de Pedido de etiquetas

    You can see that I am hiding price tables accordingly with the image I selected. I also did a calculation example; if you select Etiqueta de Bidón -> 20x10 cm -> Cantidad entre 100-500, you will see a result. 

    This approach is not the most indicated. You will have to set a lot of conditions and can probably run into errors. Maybe the best way to do that is by using an Input Table widget. Here is a helpful guide.

    Complete guide 👉 how-to-perform-form-calculation-in-the-input-table-field?


    Let us know if you need anything else.


    Have a great day 😀✨


  • Profile Image
    improntapublicidadva
    Answered on October 29, 2020 at 05:31 PM

    Thanks. I will try!!!