string[] strSTime =Convert.ToDateTime(Convert. ToDateTime(dview[0][" StartDtTime"]). ToShortTimeString()).ToString( "H:mm").Split(":".ToCharArray( ));--Here dview means dataview
txtSDate.Text = Convert.ToDateTime(Convert.ToDateTime(txtDate.Text).ToShortDateString( )).ToString("dd/MM/yyyy");--Converting date into dd/MM/yyyy format
rbl_test.SelectedValue = dview[0]["IsolationType"] == true ? "1" : "2";
TimeSpan ts;
ts = Convert.ToDateTime(Convert.ToDateTime(dview[ 0]["FinishDtTime"]). ToShortDateString()) - Convert.ToDateTime(Convert.ToDateTime(dview[ 0]["FromDate"]).ToShortDateString( ));--Calculating days using timespan in asp.net
txtSDate.Text = Convert.ToDateTime(Convert.ToDateTime(txtDate.Text).ToShortDateString(
rbl_test.SelectedValue = dview[0]["IsolationType"] == true ? "1" : "2";
TimeSpan ts;
ts = Convert.ToDateTime(Convert.ToDateTime(dview[
No comments:
Post a Comment
Comments