This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

How to Read Local JSON File in UIX?

There is a JSON file within the UIX folder, the JSON file content needs to be read and parsed.

Parsing JSON is what we got answer from a forum question. But not sure about how to read the JSON file content placed in the UIX folder.

Tried many JS approaches to read file content, but shows undefined error.

Parents Reply Children
  • In our case, we want to get different commandName from a JSON file based on input passed while calling extension method. But the problem is - we get the commandName from extension method after creating custom command. So it get's the commandName defined in UIX not from VAF Extension method. That's why tried to read JSON from UIX.

    But as you suggest to do from vault application, how to call the extension method so that I get the intended commandName before creating custom command with the name?

  • Wasn't this another forum thread? Why are you starting multiple threads about the same thing?  I seem to recall I replied to you there and I don't recall suggesting you went down this route.  Your issue there was simply timing (you needed to create the command after you've loaded the data, not before).

    If you're still having issues with that then I suggest you add a comment to this thread linking to the previous question, then continue that one.

  • Sorry, my bad. I was not able to fix the issue yet and tried to describe why wanted to parse JSON from UIX instead of VAF.

    Anyway here goes the question link of previous discussion - community.m-files.com/.../is-there-any-way-to-hide-the-context-menu-based-on-license-status