cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
akharns
Helper V
Helper V

Initialize Array

This should be easy.  I am trying Initialize Variable, type array, with the value ['20191001', '20191005'].  It thinks this is a string value.  What am I doing wrong?

1 ACCEPTED SOLUTION

Accepted Solutions
v-litu-msft
Community Support
Community Support

Hi @akharns,

 

Please use the double quotes instead of single quotes:Annotation 2019-10-14 155005.png

 

Annotation 2019-10-14 155019.png

Best Regards,
Community Support Team _ Lin Tu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

5 REPLIES 5
ScottShearer
Super User
Super User

@akharns 

Try removing the single quotes around your numbers.

 

 

If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Scott

Then I can't force it to see the array elements as strings?

Hi @akharns 

 

You can intialise the array like @ScottShearer  mentioned. Later when you want to use these values as string then use the flow expression string function for conversion.

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blogPower Automate Video Tutorials
v-litu-msft
Community Support
Community Support

Hi @akharns,

 

Please use the double quotes instead of single quotes:Annotation 2019-10-14 155005.png

 

Annotation 2019-10-14 155019.png

Best Regards,
Community Support Team _ Lin Tu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

How to loop through an array and access the elements of it ?

Do I have to use a another variable which will store the index ? 

I want something like :

for(int i = 0; i < n; i++){

  print( array[i]);

}

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Users online (3,347)