Appian Community
Site
Search
Sign In/Register
Site
Search
User
DISCUSS
LEARN
SUCCESS
SUPPORT
Documentation
AppMarket
More
Cancel
I'm looking for ...
State
Not Answered
Replies
10 replies
Subscribers
7 subscribers
Views
8473 views
Users
0 members are here
Share
More
Cancel
Related Discussions
Home
»
Discussions
»
AI and Rules
Document uploads on gridLayout
saileshd
over 7 years ago
I have a gridLayout where I am uploading a document to each record. If the Docuemnt is already uploaded to the record it displays my grid, but if the document is not uploaded it gives an error as below:
"Could not display interface. Please check definition and inputs.
Interface Definition: Expression evaluation error in rule 'icams_editlogisticsgroupeditmoduleitemroweach' at function a!applyComponents [line 195]: Invalid index (1) for list: valid range is empty"
Any Suggestions?
OriginalPostID-257489
Discussion posts and replies are publicly visible
0
gaurava322
over 7 years ago
Can u please share the code that you have written.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
gaurava322
over 7 years ago
I too have implemented Document upload component on grid layout, but never faced this issue.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Sally Mason
Appian Employee
over 7 years ago
The error indicates you are trying to access an index that does not exist; so try using a lower index than '1', use '0' instead. Let us know if that resolves your issue?
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
saileshd
over 7 years ago
Yes you are right Sally. Let me decode it... I guess I will be able to address it now :)
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Karthik
over 7 years ago
@sally, Do we have index 0? I think appian array indexes are starting from 1. Or probably I didn't understand your response well.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Sally Mason
Appian Employee
over 7 years ago
Before calling "icams_editlogisticsgroupeditmoduleitemroweach" check that the array is not null ( isnull() ) as the error mentions the "valid range is empty.
More information in these functions at
forum.appian.com/.../Array_Functions.html
forum.appian.com/.../Informational_Functions.html
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
priyankasabankar
over 7 years ago
yes, the error indicates that, the index you are reffering to is not present, checking null before passing the list may resolve the issue!
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
chetany
A Score Level 1
over 7 years ago
Be aware with using isnull on arrays. (whether CDT or primitive array).
If the variable used for the array is actually null, then null will work as expected and return true.
But, if the array is just empty (but not null), isnull will return false.
If not kept in mind, this error may cause unintended behavior.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
ayishabanum1
over 7 years ago
We need to do null check before passing the list . It may resolve the issue.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
saileshd
over 7 years ago
Yes thats right. Its resolved now. Thanks everyone!
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel