Split two dates in a cell

my cell has a value(01-01-2019 To 05-30-2019). i wanted to split these dates as start date:01-01-2019 and end date: 05-30-2019. How can i do that? please help

Hi,

Hope the following helps you.

Lets say cellValue = "01-01-2019 To 05-30-2019"

Start date : Strings.Split(cellValue.toString,"To")(0).Trim
End date : Strings.Split(cellValue.toString,"To")(1).Trim

Regards,

3 Likes

Thank you so much. It worked fine

1 Like