I'm trying to store a value in code behind so I don't have to clog my page with HiddenFields, but the value 'disappears'
I'm assuming it has to do with either scope or byval vs byref, but I don't know how I need to do it for it to work.
What I've tried to do is creating a Dim under my Partial Class, setting the value in a gridview.RowCommand, and then trying to get the value at a later button.Click
Partial Class CustNSSF_MinSide
Inherits System.Web.UI.Page
Dim vr As New vrClass
Dim _ActNo As String
Sub GV_Relations_RowCommand(ByVal sender As Object, ByVal e As GridViewCommandEventArgs) Handles GV_Relations.RowCommand
_ActNo = GV_Relations.DataKeys(index)("ActSeqNo")
Protected Sub btn_lagre_Click(sender As Object, e As System.EventArgs) Handles btn_lagre.Click
Dim test = _ActNo