TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Starlin Batista
NA
2
489
Get quantity of days between two dates in C #, Asp.net
Nov 14 2019 4:30 PM
This is the code of my two Textbox:
Textbox 1:
<asp:TextBox ID=
"txtDate1"
runat=
"server"
ReadOnly =
"true"
></asp:TextBox>
Textbox 2:
<asp:TextBox ID=
"txtDate2"
runat=
"server"
ReadOnly =
"true"
></asp:TextBox>
This is the code of my JQUERY:
<script>
$(
function
() {
$(
"[id*=txtDate1]"
).datepicker({
showOn:
"button"
,
buttonImage:
"images/calendario.png"
,
buttonImageOnly:
true
,
buttonText:
"a"
,
minDate: 0,
maxDate: 2,
dateFormat:
'dd-mm-yy'
}); });
</script>
<script>
$(
function
() {
$(
"[id*=txtDate2]"
).datepicker({
showOn:
"button"
,
buttonImage:
"images/calendario.png"
,
buttonImageOnly:
true
,
buttonText:
"a"
,
minDate: 2,
dateFormat:
'dd-mm-yy'
}); });
</script>
This is the code i was writing..on C# Asp.net
DateTime fechaUno = Convert.ToDateTime(txtDate1.Text);
DateTime fechaDos = Convert.ToDateTime(txtDate2.Text);
TimeSpan difFechas = fechaDos.Subtract(fechaUno);
I want to print the result in days in a variable
Reply
Answers (
1
)
filed with multi select value in mvc
How to show one row instead of two having one column differe