Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
Dim dt As New Date
If dt.Day() <= 16 Then
MsgBox("allow")
ElseIf dt.Day() >= 17 Then
MsgBox("disallow")
Else
Label1.Text = "error"
End If
Im the beginner for the asp.net .
I would like to allow user to view the results before 16/mm/yyyy and disallow when the date is reached after 17/mm/yyyy.....
but when i write this code in the page load.....all the msgbox i get is ("allow") althougt the date is reached after 17/mm/yyyy.....
pls help me. to solve this problem.....!


Reply With Quote


Bookmarks