<%@ Page Language=VB Debug=true %>
<script runat=server>
Sub Page_Load(ByVal Sender as Object, ByVal E as EventArgs)
If Not IsPostBack Then
MyCal.SelectedDate = DateAdd( _
Microsoft.VisualBasic.DateInterval.Month, 2, Today())
MyCal.VisibleDate = DateAdd( _
Microsoft.VisualBasic.DateInterval.Month, 2, Today())
End If
End Sub
</SCRIPT>
<HTML>
<HEAD>
<TITLE>Displaying a Date in the Calendar Control</TITLE>
</HEAD>
<BODY LEFTMARGIN="40">
<form runat="server">
Select a Date
<BR><BR>
<asp:Calendar
id="Mycal"
runat="server"
cellpadding="3"
cellspacing="3"
/>
</form>
</BODY>
</HTML>
|