Time.FromText Function in Power Query

The Time.FromText function converts a time string (text) into a time value (time type in M). It can also use a specific culture setting to interpret the format of the input.

Syntax

Time.FromText(text as nullable text, optional options as any) as nullable time

The function has the following parameters:

Example:

Power Query M

let
    Source = Time.FromText("14:45:30")
in
    Source         

The output of the above code is 14:45:30.

Example:

Power Query M

let
    Source = Time.FromText("02:15 PM")
in
    Source      

The output of the above code is 14:15:00.