|
-
April 30th, 2003, 11:11 AM
#1
Variable problem
I have a class and in the class I declared a variable public. In the page load event I set the variable to a value. When a user presses a button I reference the variable. For some reason that variable always loses its value. Why??????
Public Class Motion
public NextOne as integer
Private Sub Page_Load
NextOne = 4
End Sub
Private Sub OnButton
dim i as integer
i = NextOne
End Sub
End class
This is a very rough layout that I am doing. I trace through pageload and nextone is equal 4 but as soon as onbutton is called it changes to zero.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|