I have created a session var and I am using it in one of my pages. Sometimes the session var loses its value and nothing displays where I am using it. How am I losing this value?
Here is my code:
Sub Page_Load(Src As Object, E As EventArgs)
Dim ConnectString As String
MyConnect = New SqlConnection
connectString = ConfigurationSettings.AppSettings("ConnectStr")
MyConnect.ConnectionString = ConnectString
Lbl_Biller.text = session("UserCode")
If Not IsPostBack Then
BindGrid()
DropDown()
End If
End Sub