Problem with filling datatable with random numbers


I have met a problem during DataTable creation and filling it with random numbers. I’m trying to fill in DataTable with random numbers and no error occurs, but DataTable contains in every row the same value. I wrote results in ExcelSheet but here the same. However, when i turn on Debugging Mode the values are different and indeed are random. When I’ve opened sheet after debugging they are also random. Same when I put Message Box after Assign so the problem is surely not in WriteRange. Where is the problem? Screenshot

Hi @Scythett,
Please share your workflow.

Hello Chetan94k. Here is my workflowMain.xaml (11.9 KB)

Hi @Scythett,
Add delay of 1 second at the end of every iteration.It will work.
Only thing is execution will take time as there are 100 iterations.

Hi @Scythett

I have made some minor changes in your flow and now it is working correctly. Below are the changes:

  1. Instead of add blank row in datatable then updating the values in datatable, I am directly adding the datarow with values.
  2. Instead of declaring new random variable again and again, I have declared it once and reusing the same variable to generate new random numbers.

Here is the file: Main.xaml (12.5 KB)

1 Like

Thanks all for helping me with this issue. I really appreciate your answers.

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.