Hey Guys,
Got a question on storing a value from protcted method to a public variable then using that public variable(with value from protcted method) in another protcted method.. My explaination, so I'll show my code. I'm new to coding so pls be easy on me.. You help is appreciate a million!! Thanks!! :]
Partial Class test
Inherits System.Web.UI.Page
Dim TempVal As String = ""
Protected Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim startVal As String = "Welcome"
TempVal = startVal
End Sub
Protected Sub Button2_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button2.Click
Response.Write("val is " & TempVal)
End Sub
End Class