My requirement is to convert datetime data type to date and display it on datefi

My requirement is to convert datetime data type to date and display it on datefield sail component. I am using below expression for the same.
todate(text(local!ThroughDate,"yyyy-mm-dd"))

i am able to convert it to date but its not displaying on the datefield component but when i replaced it with textfield it works.

Any pointer on this..

OriginalPostID-137613

OriginalPostID-137613

  Discussion posts and replies are publicly visible

Parents
  • 0
    Certified Lead Developer
    I'm struggling to understand what you're trying to achieve....
    1) If local!ThroughDate is a dateTime type then it doesn't need conversion to display in a SAIL dateTimeField it will work natively.
    2) To convert a dateTime to a date you simply wrap it in todate(local!ThroughDate) so your text() function is further confusing things.
Reply
  • 0
    Certified Lead Developer
    I'm struggling to understand what you're trying to achieve....
    1) If local!ThroughDate is a dateTime type then it doesn't need conversion to display in a SAIL dateTimeField it will work natively.
    2) To convert a dateTime to a date you simply wrap it in todate(local!ThroughDate) so your text() function is further confusing things.
Children
No Data