Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

SOLVED

For loop Script in Html diffusion

El-Coder
Level 2
Level 2

Hello community,
I'm trying to do a loop in the html and concatenate fields that I want to retrieve in the mail with the increment value i of the for loop,
Here is the script I used but it didn't work,


<script> <% for(var i=0;i<5;i++) { %>  </script>
<%= i %> - <%=context.targetData.AllWkf1.name_wkf %>
<script><%}%> </script>

 

What i want is to concatenate the value i with the AllWkf and loop it until I retrieve the values that I want,
For Example : 
context.targetData.AllWkf1.name_wkf
context.targetData.AllWkf2.name_wkf

context.targetData.AllWkf3.name_wkf

context.targetData.AllWkf4.name_wkf

...

Could anyone help me with this ?

1 Accepted Solution
DavidKangni
Correct answer by
Community Advisor
Community Advisor

Hello 

 

Scripting is not officially allowed in ACS.

Thanks,

David

View solution in original post

3 Replies
DavidKangni
Correct answer by
Community Advisor
Community Advisor

Hello 

 

Scripting is not officially allowed in ACS.

Thanks,

David

View solution in original post

El-Coder
Level 2
Level 2

HI @DavidKangni , Thank you for your time,
I would like to know if scripting will be allowed in ACS future releases?

DavidKangni
Community Advisor
Community Advisor

There are multiple enhancement requests for this scripting functionality but we don't have any tentative release dates at this time.

If you have an account manager, you may ask him if it's on 2021 roadmap.

Thanks,

David