Adding ten minutes to a tike

Hi All,

I have a requirement to add 10 mins to given time

For example input 8.35 AM
Output 8:45 AM

Can we achieve this dynamically

Hi @heisen567

Try this

DateTime.ParseExact(“8:35 AM”, “h:m tt”, System.Globalization.CultureInfo.InvariantCulture).AddMinutes(10).ToString(“h:m tt”)

1 Like

Basically instead of 8.35 pass a variable dynamically if needed


DateTime.ParseExact(yourInputTime, “ tt”, System.Globalization.CultureInfo.InvariantCulture).AddMinutes(10).ToString(“h:mm tt”)

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.