Re: Expression to pass blank dates from Excel to SharePoint list
@third_learner In Excel, is the date column blank? Or does it display #VALUE!?
If it displays #VALUE then the expression has to be adjusted to see if the column is equal to #VALUE! and not ''.
Can you insert the dynamic content of the date column into a Compose action (as shown below) and screenshot the output of the Compose action when the date field is empty?

If the Compose action returns #VALUE! adjust your expression.
if(contains(items('Apply_to_each_2')?['Resources Assigned Date'], '#VALUE!'),
null,
items('Apply_to_each_2')?['Resources Assigned Date'])If you don't select ISO8601, Excel will return the date in numerical format. To format your date, you need to use a formatDateTime() function. The addDays() function isn't required if you set the DateTime format to ISO8601
if(contains(items('Apply_to_each_2')?['Resources Assigned Date'], '#VALUE!'),
null,
formatDateTime(items('Apply_to_each_2')?['Resources Assigned Date'], 'dd-MM-yyyy'))
Hope this helps!
If I helped you solve your problem—please mark my post as a solution ✅. Consider giving me a 👍 if you liked my response!
|