How to use switch control flow?

studio

#1

Can anyone please share the program with how to use switch flow?
I want to replace month name with month number
for example 08 sep 2017 replace “sep” with “/09/”.
and so on for every month.
i want to make cases for all 12 months.

Thanks and Regards,
Prajakta


#2

Hello!

There’re a couple ways to do that.

Here’s a example with 2 months to be replaced (jan and feb). Try to do the rest on your own! Any doubts please let me know.

Link: changeMonth_Example (Flow switch).xaml (12.3 KB)

Hope It Helps!

Regards,

@EDIT: If you can’t download with a single click on the link. Click right and select “Save As”


#3

hi Lucas yes it works

Thank you
but i can not attach month dec as there are 12 nodes to switch statement and assigning first “month” where initial input is given takes one node already.


#4

Okay. You can use “Switch” instead of “Flow Switch” to add as many condition as you need :smiley:

Example:

image


#5

superlike


#6

it says jan is not a valid value for int32 :frowning:


#7

Just change on the property to “String”

Good Luck with your automation!


#8

now it works thank you :slight_smile:


#9

I know this is already solved… but there is one more option using assign activity with - Date.ParseExact(StrDate, “dd MMM yyyy”, System.Globalization.DateTimeFormatInfo.InvariantInfo).ToString(“dd/MM/yyyy”)