Skip to main content
March 11, 2025
Question

adding a small condition Grid column label parameter?

  • March 11, 2025
  • 5 replies
  • 0 views

adding if condition in the label parameter of grid column, if local!docids are not available then column should be blank and otherwise Uploaded documents.

Can you please help on this.

Thanks for your thoughts on this.

    5 replies

    venkatrea696188
    March 11, 2025

    Hi [mention:1bf28746db314580b1a6e5d32121e4b3:e9ed411860ed4f2ba0265705b8793d05] ,

    It's a known behavior of is null or empty function it will gives false for empty array .We have many approaches for example try using length function like 

    if(length({array})<=0,"","Upload documents")

    March 11, 2025

    Hi. To complement [mention:ba9672c2f5294cb98c0a2b8fb79cf967:e9ed411860ed4f2ba0265705b8793d05]  suggestion, if there's a case where the variable "local!docsIds" is not a list, the length() function will return an error. To solve it, use the following code:

      if(
        or(
          a!isNullOrEmpty(local!docs),
          length(local!docs) = 0
        ),
        "",
        "Uploaded Documents"
      )

    stefanhelzle0001
    March 11, 2025

    More on null checking in my blog post: appian.rocks/.../

    March 12, 2025

    Thank you so much stefan, this post helped me to resolve the issue.

    March 12, 2025

    Hi [mention:1bf28746db314580b1a6e5d32121e4b3:e9ed411860ed4f2ba0265705b8793d05] ,

    In addition to the previous answers, another possible solution is: