Skip to main content

Notifications

Power Platform Community / Forums / Building Flows / HTML Table: Convert in...
Building Flows
Suggested answer

HTML Table: Convert int to date format

Posted on by 31
Hi Everyone,
 
I'm trying to create a flow which 
  • reads an Excel named table from an Excel worksheet which contains appliance serial number, model, support end date and customer,
  • selects relevant columns (serial number, model, support end date),
  • selects the appliances that are past the support end date,
  • creates an HTML table with those appliances,
  • sends an email with the HTML table embedded in the mail body. 
 
Here is my Excel table:
    
 
Serial Number Appliance Model Support End Date Customer
FRZ001691 FRZ003 12/31/2024 Tolga Industries
FRZ001532 FRZ003 12/31/2024 Tolga Industries
FRZ001037 FRZ003 12/31/2023 Tolga Industries
DSW001616 DSW001 12/31/2024 Tolga Industries
LAU001216  
LAU001
12/31/2024 Tolga Industries
DSW001316 DSW001 12/31/2024 Tolga Industries
FRZ001691 FRZ003 12/31/2022 Tolga Industries
LAU001150 LAU002 12/31/2024 Tolga Industries
LAU1121 LAU002 12/31/2024 Tolga Industries
DSW001280 DSW001 12/31/2023 Tolga Industries
 
 
 
Here is my flow;
  

 
 
 
Here is the HTML table in the email:
 
 
 
 
So, the flow works. But as you see in the HTML table above, the date is in integer format. 


My question is, how I can accomplish the same email/HTML table, but with the correct date formatting - for example DD-MM-YYYY.
 


Thank you
 
Tolga
  • Nived_Nambiar Profile Picture
    Nived_Nambiar 15,886 on at
    HTML Table: Convert int to date format
    Hi, 
     
    for doing date comparison - i would recommend to find difference b/w dates in terms of days/month etc using ticks function, refer below post for getting more details on that
     
    So here if we take an example of 2 dates,
     
    date1= 2021-10-25
    date2= 2021-10-26
     
    now to check whether date2>date1, take the difference b/w date2 and date1 using ticks function as mentioned in the above blog and then see whether the resultant of that ticks function returns positive value  or not, if positive value- then it implies that date2>date 1
     
    Hope it helps !
     
    Mark it as solution if it resolves your query !
     
     
  • tolga-balci Profile Picture
    tolga-balci 31 on at
    HTML Table: Convert int to date format
    Hi Nived,
     
    Thanks for your reply. 
     
    I just could not figure out how I would be able to perform date operations - less than, greater than - if I select ISO date format. Can you please clarify?
     
    Thank you.
    Tolga
  • Suggested answer
    Nived_Nambiar Profile Picture
    Nived_Nambiar 15,886 on at
    HTML Table: Convert int to date format
    Hi,
     
    In the list rows in table action - make sure to select the below highlighted value to show date in ISO format rather than as a number.
     
     
    if after that date appears but not in desired format, use format datetime expression to convert date to desired format.
     
    Hope it helps !
     
    Thanks & Regards,
    Nived N
     
    Mark it as solution if it helps !

Helpful resources

Quick Links

Welcome to the Power Platform…

We are thrilled to unveil the newly-launched Power Platform Communities!…

Community Update Sept 16…

Power Platform Community Update…

Welcome to the new Power Platform Community!…

We are excited to announce our new Copilot Cookbook Gallery in the Community…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 140,745

#2
RandyHayes Profile Picture

RandyHayes 76,308

#3
Pstork1 Profile Picture

Pstork1 63,355

Leaderboard

Featured topics