While loop with continue activity

I am having while loop inside while loop i am having invoke Activity ( another workflow)

In that invoke workflow i am having if condition -

My doubt is if condition true means it’s going then block -
In that then block i need a CONTINUE Activity - no need to go for further activities , but i am getting error while using continue activity

  • any other activities there for skip the loop any one help pls

@BHUVAN ,

Could you please share the screenshot of the error that you are getting in Continue activity.

Warm Regards,
Ashwini Kempraj

You can use Continue only at same level (same workflow) as the While loop is defined.
You can NOT use Continue from invoked workflow to “continue” a While loop defined in “invoking” (outer) workflow.

You will need to use some different technique to exit from invoked workflow.

Is the Invoke Workflow the only activity in While loop?

Cheers

I am having another doubt - invoke workflow in while loop activity - i increase the count value means it’s increase or not can u pls tell me

@BHUVAN

Just an example inside invoke to increase count you can use this

Select Case Weekday(startDate,VBMonday)
Case 1
If row(“Pattern”).ToString.Contains(“1”) Then
in_Count=in_Count+1
End If
Case 2
If row(“Pattern”).ToString.Contains(“2”) Then
in_Count=in_Count+1
End If
Case 3
If row(“Pattern”).ToString.Contains(“6”) Then
in_Count=in_Count+1
End If
Case 4
If row(“Pattern”).ToString.Contains(“7”) Then
in_Count=in_Count+1
End If
End Select

Hope it helps,
Cheers

3 Likes

You given answer like if - while loop -inside invoke workflow i am increasing count value men’s it’s changing main while loop or not that’s my doubt

@BHUVAN
Yes you can send the count out of invoke so the count will be increased you are going to increase the count inside the invoke right then its fine.

Regards,

thanks for clarifying @Chirag_Shetty_Divakar i am confusing that’s part now i am cleared :heartbeat::sparkles:

1 Like

To increase counter, that is defined at outer while loop level, in the invoked workflow you have to pass the counter variable as in/out argument to the invoked workflow.

More to learn here

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