How to assign today as selected date on calendar control

Discussion in 'ASP .Net' started by KatB, Feb 2, 2005.

  1. KatB

    KatB Guest

    I have a calendar control which renders on page load. I need the initial
    rendering to have a selected day (today) and not wait for the first
    SelectionChanged event to occur.

    Any suggestions?

    Thanks, Kat

    *** Sent via Developersdex http://www.developersdex.com ***
    Don't just participate in USENET...get rewarded for it!
     
    KatB, Feb 2, 2005
    #1
    1. Advertising

  2. Not sure what you mean, but maybe it is just to set the SelectedDate and
    VisibleDate to Now as shown below?

    Private Sub Page_Load _
    (ByVal sender As System.Object, _
    ByVal e As System.EventArgs) _
    Handles MyBase.Load
    Calendar1.SelectedDate = Now
    Calendar1.VisibleDate = Now
    End Sub

    Ken
    Microsoft MVP [ASP.NET]
    Toronto

    "KatB" <> wrote in message
    news:%...
    >I have a calendar control which renders on page load. I need the initial
    > rendering to have a selected day (today) and not wait for the first
    > SelectionChanged event to occur.
    >
    > Any suggestions?
    >
    > Thanks, Kat
    >
    > *** Sent via Developersdex http://www.developersdex.com ***
    > Don't just participate in USENET...get rewarded for it!
     
    Ken Cox [Microsoft MVP], Feb 2, 2005
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Michael England
    Replies:
    0
    Views:
    609
    Michael England
    Nov 26, 2003
  2. =?Utf-8?B?UGV0ZXI=?=

    ASP.NET Calendar control's selected date

    =?Utf-8?B?UGV0ZXI=?=, Apr 23, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    5,508
    Philip Q [MVP]
    Apr 23, 2004
  3. Mark Olbert
    Replies:
    7
    Views:
    1,468
    Patrice
    Jan 20, 2010
  4. John Grandy
    Replies:
    0
    Views:
    344
    John Grandy
    Jun 8, 2007
  5. Kelly
    Replies:
    0
    Views:
    636
    Kelly
    Mar 18, 2009
Loading...

Share This Page