Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: ASP.NET Javascript
hi,
 
i want a calendar control in javascript and then want to plug in asp.net.. anyone help me for writing the code....
Posted 13-Dec-11 1:55am
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 3

Hi Gopinath,
CP is such a wonderfull site before posting your question, try to search for the existing articles[^]
This is quite a basic question.
you can start from here A JavaScript Weekly Calendar[^]
  Permalink  
v2
Comments
RaviRanjankr at 16-Dec-11 15:31pm
   
My 5+
Pramod harithsa at 17-Dec-11 4:00am
   
thanks :-)
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 5

Use jquery datepicker. Its very light weight and easy to integrate and use in you ASP.NET application.
 
Add following javascript.
 
 
<link rel="stylesheet" href="http://code.jquery.com/ui/1.10.2/themes/smoothness/jquery-ui.css" />
<script src="http://code.jquery.com/jquery-1.9.1.js"></script>
<script src="http://code.jquery.com/ui/1.10.2/jquery-ui.js"></script>
<link rel="stylesheet" href="/resources/demos/style.css" />
   
 
<script type="text/javascript">
        $(function () {
            $("#<%=txtFromDate.ClientID %>").datepicker({ dateFormat: 'M dd, yy' });
        });
</script>
 
Then add Textbox that is to be used as calendar.
 
 <asp:textbox id="txtFromDate" runat="server" width="150px" xmlns:asp="#unknown"></asp:textbox>
 

On server side, you will easily get the selected date as txtFromDate.Text.
  Permalink  

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

  Print Answers RSS
0 OriginalGriff 350
1 Jochen Arndt 190
2 Richard MacCutchan 135
3 Sergey Alexandrovich Kryukov 120
4 DamithSL 95
0 OriginalGriff 6,045
1 DamithSL 4,611
2 Maciej Los 4,087
3 Kornfeld Eliyahu Peter 3,480
4 Sergey Alexandrovich Kryukov 3,310


Advertise | Privacy | Mobile
Web01 | 2.8.141220.1 | Last Updated 14 Mar 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100