Help Needed: sendCommand not working with arrayList of String

I’d start by breaking it down into steps. Do the array get, show the expected string with logInfo and see if it is what you expect.

There is a completely different approach to this kind of requirement based on OH Groups
Example shows how to work through the Items in a Group