Forum Discussion

Srini1053's avatar
Srini1053
New Member
3 years ago
Solved

Convert Text Data Type to Date?

Hi All,   I am newbie here. I am trying to convert text data type to date, but i am getting an error.  Could you please help me on this?  
  • Ahmedx's avatar
    3 years ago

    plse try this

    try
    Date.FromText("01/"&[Date], [Format="dd/M/yy", Culture="en-EN"]) otherwise 
    try Date.FromText("01/"&[Date], [Format="dd/MM/yy", Culture="en-EN"]) otherwise Date.From(DateTime.LocalNow())

    or

    try
    Date.FromText("01/"&[Date], [Format="dd/M/yy", Culture="en-EN"]) otherwise 
    try Date.FromText("01/"&[Date], [Format="dd/MM/yy", Culture="en-EN"]) otherwise null