Click here to Skip to main content
15,891,864 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Hi all,
I am developing a contact us form . In that i need to get the From date with time and To date along with time.Can anyone provide me the code for implementing this in my asp .net web application. Thanks in advance.
Posted
Comments
Sandeep Mewara 4-May-13 7:11am    
It does not work like this here.

Here is what is expected of enquirers:
1. TRY first what you want to do! You may find that it's not that hard.
2. Formulate what was done by you that looks like an issue/not working.

Try them and tell if you face issues.
Members will be more than happy to help like this.
ajithk444 4-May-13 7:18am    
Can u tel me how can i get the time also in this code which uses JQuery. ??

XML
<html xmlns="http://www.w3.org/1999/xhtml">
    <head runat="server">
    <title>jQuery Datepicker Demo</title>
    <style type="text/css">
        div.ui-datepicker
        {
            font-size: 10px;
        }
    </style>
    <link rel="stylesheet" href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.2/themes/start/jquery-ui.css" type="text/css" media="all" />
    <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js" type="text/javascript"></script>
    <script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.2/jquery-ui.min.js" type="text/javascript"></script>
    <script type="text/javascript">
        $(document).ready(function () {
            $('#txtDateFrom,#txtDateTo').datepicker({
                changeYear: true,
                beforeShow: function (textbox, instance) {
                instance.dpDiv.css({
                    marginTop: (-textbox.offsetHeight) + 'px',
                    marginLeft: textbox.offsetWidth + 'px'
                });
                }
            });
        });
    </script>
    </head>
    <body>
     <form id="testForm" runat="server">
        <div>
            <input type="text" id="txtDateFrom" /><br />
            <input type="text" id="txtDateTo" />
        </div>
     </form>
    </body>
</html>



Hi ,I have created through this. I can get the date but i am not able to find any tool in jquery whether any such tool available for getting time also. Am just asking for some reference links if possible.
 
Share this answer
 
Refer This Sites and add plugins into your page:-

http://jqueryui.com/datepicker/[^]
http://timjames.me/jquery-ui-datetimepicker-plugin[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900