vLookup Refresh Errors with Field On Change Rule

Forums vLooup for SharePoint vLookup Refresh Errors with Field On Change Rule

Viewing 1 reply thread
  • Author
    Posts
    • #34937
      Anthony Reroma
      Participant

      Hi Alexander,

      On my New Form I created a rule to refresh the vLookup results field when the source field changes. I followed your instructions from the other forum topics and added this JS function to the “Run these functions” section on the Rules page. vLookupState is my lookup results field.

      function refresh_vLookup(){
      spjs.vLookup._init(“vLookupState”,false,true);
      }

      However after creating this rule, I am now getting these errors (please see screenshots of errors and rule setup):

      The rule “vLookupRefresh” tried to invoke the function “function refresh_vLookup(){
      spjs.vLookup._init(“vLookupState””

      Error:
      TypeError: Object doesnt support property or method

      Please advise. Thank you.

      Regards,
      Anthony

    • #34950
      Alexander Bautz
      Keymaster

      Hi,
      You cannot put the function declaration in the “Run these functions” textarea – put it in custom js like this:

      function refresh_vLookup(){
      spjs.vLookup._init(“vLookupState”,false,true);
      }

      and add only the function name in the “Run these functions” textarea:

      refresh_vLookup

      Alexander

      • #35082
        Anthony Reroma
        Participant

        Thanks Alex! This worked for me. Learning valuable knowledge with DFFS.

Viewing 1 reply thread
  • You must be logged in to reply to this topic.