How do I convert 1:00 PM or 11:56 PM to 24 hour clock time in Power Query?
Thanks
Robb
Hi
in Power Query Editor, format to time, create a custom column
Time.ToText([Time], "hh:mm")
let
Source = Excel.CurrentWorkbook(){[Name="Table1"]}[Content],
#"Changed Type" = Table.TransformColumnTypes(Source,{{"Time", type time}}),
#"Added Custom" = Table.AddColumn(#"Changed Type", "Custom", each Time.ToText([Time], "hh:mm"))
in
#"Added Custom"
Hi Robert,
Chris' solution converts the times to text which will render them useless in formulas when you Close & Load. This may not be a problem, but if it is, you should apply the formatting once the data lands in Excel. Power Query is not where you do the formatting. Power Query is for getting the data, cleaning it and loading it to Excel where you can apply the formatting.
Mynda