Forum Discussion

MichelleLabbe's avatar
MichelleLabbe
Qrew Member
3 years ago

Dynamic Form Rules to hide address subfields

Hello, 

I am trying to display latitude/longitude coordinates on the map using the Address field. This only works if the lat/long are entered in the Address:Street 1 and Address:Street 2 subfields AND no other address subfields are populated. Once any of other subfields have information in them, the lat/long is overridden and the lat/long location does not display on the Map.

To reduce confusion for users entering this data, I am trying to use the Dynamic Form Rules to hide the other Address subfields when the Street 1 and Street 2 are populated with lat/long.

Here is the rule I came up with, which is not working to hide the other subfields when Street 1 and Street 2 are populated. Can anyone help straighten me out? Thanks!


------------------------------
Michelle Labbe
------------------------------

8 Replies

  • I don't believe that you can add the subfields, but you could have a form rule to blank them out.

    ------------------------------
    Mark Shnier (YQC)
    mark.shnier@gmail.com
    ------------------------------
    • MichelleLabbe's avatar
      MichelleLabbe
      Qrew Member
      Hi, thanks. -- yes, I am trying to "blank them out" with the Form rules. The Rule I wrote is not working (see screenshot from original post)...

      ------------------------------
      Michelle Labbe
      ------------------------------
      • MarkShnier__You's avatar
        MarkShnier__You
        Qrew Champion
        By blank them out I don't mean hide the fields (as I don't believe you can do that for parts of an address "field" - its show hide all or nothing), I mean change any data entry in those fields to be blank.

        ------------------------------
        Mark Shnier (YQC)
        mark.shnier@gmail.com
        ------------------------------
  • Does the person submitting the details for your Street 1 and Street 2 fields have the option to submit an actual address  or  submit latitude and longitude?

    If so, this might work for you:
    • Add a field to have the person submitting select if they are submitting an actual address or Lat/Long
      • Hide the address fields until this is selected
      • Once selected, provide the appropriate fields that should be used for those options
    This way if they are submitting Lat/Long they would not have access to the additional fields. 


    ------------------------------
    Amber Anderson
    ------------------------------
    • MarkShnier__You's avatar
      MarkShnier__You
      Qrew Champion
      Amber, the address subfields cannot be individually hidden.  That's the issue.

      ------------------------------
      Mark Shnier (YQC)
      mark.shnier@gmail.com
      ------------------------------
      • AmberAnderson's avatar
        AmberAnderson
        Qrew Trainee
        Perhaps the same set up with the drop down of selecting Full Address or Lat/Long and instead of hiding make a Dynamic rule that:
        • Make them read only
        • Clear out the extra fields as well (incase someone entered something and didn't clear them out. 


        ------------------------------
        Amber Anderson
        ------------------------------
  • I think I've found a way to make this work.

    Set up text fields for the lat and long values. Add these to the form, along with the address field. Set the address field to only show when viewing the record (so users don't have the option to edit it). Then, set up form rules as such:


    ...and...


    I wasn't sure if the form rule would populate the values in the address field if the field wasn't displayed when adding/editing, but it seems to work.


    Hope this helps. Also, I'm curious--what exactly is the "known bug" QB mentions in their response?

    ------------------------------
    Dan Ladner
    ------------------------------