Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
If Not Page.IsPostBack Then
lbIdArticolo.Text = ""
..............
End If
End Sub
Protected Sub btAggCarrello_Click(sender As Object, e As EventArgs) Handles btAggCarrello.Click
If IsNothing(Session.Item("UtenteID")) Then
lbErrore.Visible = True
lbErrore.Text = "Per acquistare devi effettuare il Login"
Exit Sub
End If
End Sub
Ecco uno schema delle due procedure.