Wrox Home  
Search P2P Archive for: Go

  Return to Index  

aspx_beginners thread: passing global variables between subs


Message #1 by "John Tyson" <jtyson@t...> on Tue, 25 Mar 2003 13:57:14 -0800
Hi,

I have a page where in my page load sub between If Not Page.IsPostBack I
grab a value from a stored procedure output parameter and assign it to a
string variable.  I created this string variable just after my <script>
tag to make sure it would be available to all subs.

My global variable is assigned the correct value in my page load sub,
but when I try and use this variable in my next sub, which is a postback
based on a value changed in a dropdown list in my page, the string
variable is nothing.  Why does it lose the value between subs?  Help?

Thanks,

John

  Return to Index