I had a Start time stored in variable and i had some value in another variable which is in mins. I want to - or + the same value from startTime

I had a Start time stored in variable and i had some value in another variable which is in mins. I want to - or + the same value from startTime

How we can do this. Please suggest.

Note - start time is DateTime variable and another variable is string

you can use .addminutes(-cint(yourminutevariable))

or use + for add

e.g.

time.now.addminutes(-cint(yourminutevariable))

now will add or minus onto current time but here i have already a time like my start time is 1 PM and let say 20 is in string variable then i need

Arrival time as 1:20 and Depart time as 40 mins

@Puneet_Singh

Try like this

StartTime.AddMinutes(Cint(str)) for adding

StartTime.AddMunites(-Cint(str)) for subtracting

To convert to string as required time add .ToString("hh:mm tt")

Cheers

grafik