Hi nauna,
Refer below sample.
First you need to calculate total minutes from what time data you have. And then add both calulated total minute.
Code
C#
protected void Page_Load(object sender, EventArgs e)
{
item.Text = "24:17".Replace(" hours ", ":").Replace("min", "").Replace("hour", ":").Replace("min", "");
// Calculate total minutes.
int itemTotalMinutes = (Convert.ToInt32(item.Text.Split(':')[0]) * 60) + Convert.ToInt32(item.Text.Split(':')[1]);
lblholdingtime.Text = "25:59".Replace(" hours ", ":").Replace("min", "").Replace("hour", ":").Replace("min", "");
// Calculate total minutes.
int holdingtimTotalMinutes = (Convert.ToInt32(lblholdingtime.Text.Split(':')[0]) * 60) + Convert.ToInt32(lblholdingtime.Text.Split(':')[1]);
// Calculate total minutes from both.
int totalMinute = itemTotalMinutes + holdingtimTotalMinutes;
// Convertint to Hours and minutes.
Response.Write((totalMinute / 60) + " Hours : " + (totalMinute % 60) + " minutes");
}
VB.Net
Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs) Handles Me.Load
item.Text = "24:17".Replace(" hours ", ":").Replace("min", "").Replace("hour", ":").Replace("min", "")
Dim itemTotalMinutes As Integer = (Convert.ToInt32(item.Text.Split(":"c)(0)) * 60) + Convert.ToInt32(item.Text.Split(":"c)(1))
lblholdingtime.Text = "25:59".Replace(" hours ", ":").Replace("min", "").Replace("hour", ":").Replace("min", "")
Dim holdingtimTotalMinutes As Integer = (Convert.ToInt32(lblholdingtime.Text.Split(":"c)(0)) * 60) + Convert.ToInt32(lblholdingtime.Text.Split(":"c)(1))
Dim totalMinute As Integer = itemTotalMinutes + holdingtimTotalMinutes
Response.Write((totalMinute / 60) & " Hours : " & (totalMinute Mod 60) & " minutes")
End Sub
Output
50 Hours : 16 minutes