Skip to main content
Question

Count Line Items

  • November 23, 2022
  • 1 reply
  • 508 views

I referred to your previous post about this but unfortunately it is now closed but also the code is not working.  It is returning a 0 even though the input has 3 comma separated items.

Please can anyone help.

Here is the code again:

 

let items = [];

if (inputData.names) { items = inputData.names.split(","); }

return [{ length: items.length }];

This post has been closed for comments. Please create a new post if you need help or have a question about this topic.

1 reply

Troy Tessalone
Zapier Orchestrator & Solution Partner
Forum|alt.badge.img+14
  • Zapier Orchestrator & Solution Partner
  • November 23, 2022

Hi @lkfunnel 

Good question.

Please post detailed screenshots with how your Code step is configured in order for us to have proper context.