How to check Buying Start Date = Any date between "Begin DT" and "Due DT" in IF condition using Uipath

HI Everyone,

Example, How to check in IF condition or any condition, How to write the condition syntax.

  1. Buying Start Date = Begin DT
  2. if not, check Buying Start Date = Any date between “Begin DT” and “Due DT” is also fine.
  3. if above 2 fails, we can throw error.
1 Like

Hi @Koteswara_Rao ,

try this expression in condition

DateTime.ParseExact(beginDate,“date format(ex:- MM/dd/yyyy HH:mm:ss)”,System.Globalization.CultureInfo.InvariantCulture).ToString(“dd-MMM-yyyy”) >= DateTime.ParseExact(startdate,“date format(ex:- MM/dd/yyyy HH:mm:ss)”,System.Globalization.CultureInfo.InvariantCulture).ToString(“dd-MMM-yyyy”)+ AND DateTime.ParseExact(dueDate,“date format(ex:- MM/dd/yyyy HH:mm:ss)”,System.Globalization.CultureInfo.InvariantCulture).ToString(“dd-MMM-yyyy”) <= DateTime.ParseExact(startdate,“date format(ex:- MM/dd/yyyy HH:mm:ss)”,System.Globalization.CultureInfo.InvariantCulture).ToString(“dd-MMM-yyyy”)

Let me know if you find any difficulty in applying this formula.

Happy Learning,
Achal Sharma

Hi @Koteswara_Rao,

Can you please elaborate more on this?

Thanks

Hi @Koteswara_Rao,

Please, take a look at the attached file

Main.xaml (9.4 KB)

ok…Its working fine

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