Get Mobile calendar selected date (VB.net) : Calendar « Mobile Control « ASP.Net






Get Mobile calendar selected date (VB.net)

<%@ Page 
    Inherits="System.Web.UI.MobileControls.MobilePage" 
    Language="VB" 
%>
<%@ Register 
    TagPrefix="mobile" 
    Namespace="System.Web.UI.MobileControls" 
    Assembly="System.Web.Mobile" 
%>
<script runat="server" language="VB">
Sub calSelectChange(ByVal Sender as Object, _
    ByVal E as EventArgs)
    Dim i as Integer
    lbl1.Text = "You selected:"
    For i = 0 to Cal1.SelectedDates.Count - 1
        lbl1.Text = lbl1.Text & " " _
            & Cal1.SelectedDates(i).ToShortDateString()
    Next    
End Sub
</script>
<mobile:form 
    id="FirstPage" 
    runat="server">
    <mobile:calendar  
        id="Cal1"
        selectionmode="DayWeekMonth"
        onselectionchanged="calSelectChange"
        runat="server"
    />
    <mobile:label
        id="lbl1"
        runat="server"
    />
</mobile:form>

           
       








Related examples in the same category

1.Mobile calendar selection mode (VB.net)
2.Mobile date selection changed event (VB.net)
3.Simplest mobile calendar (VB.net)