asp.net javascript datediff of 2 textbox dates

I have 2 textboxes that I want to enter dates into and a third textbox I want to automatically enter the number of days (datediff +1) difference of the 2 dates. I need to NOT have a postback for this and want to accomplish it in javascript. Would need it to evaluate if the text in the textboxes are actual dates (isdate()) and perform the calculation when leaving either textbox and fill in the third textbox with the number. Any help would be greatly appreciated!  
CubbybulinAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

SwapnilSoftware ArchitectCommented:
Hi Cubbybulin,

        There are multiple ways available. Please check below for solution.

       http://stackoverflow.com/questions/542938/how-do-i-get-the-number-of-days-between-two-dates-in-jquery

Thanks,
netswap
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
CubbybulinAuthor Commented:
I am trying to use this solution from the link you provided. I am not sure how to invoke it though when a date is entered into either of the two textbox's (on textchanged) and then enter the value into the third textbox.

 <script type="text/javascript" src="date.js"></script>
       
<script type="text/javascript">                
var minutes = 1000*60;                
var hours = minutes*60;                
var days = hours*24;                  
var foo_date1 = getDateFromFormat("02/10/2009", "M/d/y");                
var foo_date2 = getDateFromFormat("02/12/2009", "M/d/y");                
var diff_date = Math.round((foo_date2 - foo_date1)/days);                
alert("Diff date is: " + diff_date );         </script>
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
JavaScript

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.