Conditions: Could you suggest an alternate method of doing this?

  • AgilityAssoc.Canada
    Asked on April 12, 2018 at 9:45 AM

    Hi JF,

    I need a suggestion on how to accomplish this. On /80968322459972/ I am using Spreadsheet 2 Form widget. It only appears if a person indicates they are a member.

    If they say no, down further they select the Prov they are in from a drop down. Each prov has a value associated with it for tax purposes, for example BC= .12,  AB= .05 and so on. This works great.

    If they select Yes for member. The widget cannot set the province, so, I created a text input box, Prov/State, where a two character alpha can be entered.  Now the widget can fill in the value.

    I hide one or the other of the inputs based on YES NO selection.

    Then I created a condition for tax, example, if BC is value then condition is: If Prov is equal to BC $.05 * Books Price into Plus Tax and so on. It works in a fashion, but if the Prov/State value is changed to AB it won't edit the Plus Tax box unless I add the quantity again. 

    Could you suggest an alternate method of doing this?

    Thank you, Robert

  • gizem
    Replied on April 12, 2018 at 12:09 PM

    Hello Robert,

    I think you should not use the form calculation widget for your Plus Tax field. Because you are calculating this field in two different locations.(conditions and widget's own settings). It is probably causing the problem.

    I suggest you creating all calculations with conditional logic for your plus tax field. It would be better if you can change it to the number field.

    Please try it out again. If things go to more complex for you, could you please share your spreadsheet with us and explain the progress again? So, we can understand you and help you with your case further.

    Thank you for your understanding.

  • AgilityAssoc.Canada
    Replied on April 12, 2018 at 1:20 PM

    Hi,

    Thank you, this works much better.

    Best Regards, Robert

  • AgilityAssoc.Canada
    Replied on April 13, 2018 at 11:21 AM

    Hi,

    Now I have the Plus Tax box working but for the fact that I cannot get it to display a $ sign. I am thinking that injected css presidio class :ahead, would do it but I can't remember how. On the French version I will want it after. 

    Or is there another method I should use.

    Thanks, Robert

  • TREVON
    Replied on April 13, 2018 at 1:01 PM

    I have a workaround that I think will work for your case. Since you are not using the sub-label section of the "Plus tax" field you can add "$" in the sub-label section of your field as shown below

    1523638665Screen Shot 2018 04 13 at 19 Screenshot 10

    You will then inject the following CSS to your form to move the sub-label section of your field to be just before the field itself.

    https://www.jotform.com/help/117-How-to-Inject-Custom-CSS-Codes

    #label_input_68{
      margin-top: -20px;
      margin-left: -15px;
      font-weight: bold;
    }

    Below is a clone of your form with the above implemented:

    https://form.jotform.com/81024610423947

    Kindly feel free to clone and use the form.



  • AgilityAssoc.Canada
    Replied on April 13, 2018 at 3:31 PM

    Hi,

    Great... It did the job, I did alter the css a bit;

    #cid_68 label {
        color : #009900;
        font-size : 10pt !IMPORTANT;
        margin-left : 4px;
        margin-top : -18px;
    }

     I used the advanced css editor. 

    Thank you,

    Robert