<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://weblogs.asp.net/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Public Variables In VB.NET Modules</title><link>http://weblogs.asp.net/wallen/archive/2003/10/21/32854.aspx</link><description>Interesting bit of detective work the other day I thought I'd share with everyone. A friend of a friend was having trouble with an ASP 2.0 project that was ported to ASP.NET. Turns out that on some web servers the different clients were getting their</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP1 (Build: 20510.895)</generator><item><title>re: Public Variables In VB.NET Modules</title><link>http://weblogs.asp.net/wallen/archive/2003/10/21/32854.aspx#7099874</link><pubDate>Thu, 28 May 2009 09:16:19 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:7099874</guid><dc:creator>PushkarK</dc:creator><author>PushkarK</author><description>&lt;p&gt;Thank. I wanted to confirm my understanding of module variables. This post confirms that my understanding was perfect.&lt;/p&gt;
&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7099874" width="1" height="1"&gt;</description></item><item><title>re: Public Variables In VB.NET Modules</title><link>http://weblogs.asp.net/wallen/archive/2003/10/21/32854.aspx#6646941</link><pubDate>Mon, 29 Sep 2008 12:30:38 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:6646941</guid><dc:creator>Wynand Murray</dc:creator><author>Wynand Murray</author><description>&lt;p&gt;Simply use the following way for storing and retrieving a value accross your ASP.NET pages:&lt;/p&gt;
&lt;p&gt;*****Storing a value*****&lt;/p&gt;
&lt;p&gt;session(&amp;quot;myVariable&amp;quot;) = &amp;quot;assign value here&amp;quot;&lt;/p&gt;
&lt;p&gt;*****Retrieving a value*****&lt;/p&gt;
&lt;p&gt;textbox1.text = session(&amp;quot;myVariable&amp;quot;)&lt;/p&gt;
&lt;p&gt;Remember: By Default, these session variables lose their values after 20 minutes since this is the default timeout in ASP.NET. To change this timeout length, simply modify your web.config file accordingly.&lt;/p&gt;
&lt;p&gt;Happy Coding!&lt;/p&gt;
&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=6646941" width="1" height="1"&gt;</description></item><item><title>session variable in vb net</title><link>http://weblogs.asp.net/wallen/archive/2003/10/21/32854.aspx#6205137</link><pubDate>Tue, 20 May 2008 20:56:16 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:6205137</guid><dc:creator>session variable in vb net</dc:creator><author>session variable in vb net</author><description>&lt;p&gt;Pingback from &amp;nbsp;session variable in vb net&lt;/p&gt;
&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=6205137" width="1" height="1"&gt;</description></item><item><title>re: Public Variables In VB.NET Modules</title><link>http://weblogs.asp.net/wallen/archive/2003/10/21/32854.aspx#6000945</link><pubDate>Thu, 20 Mar 2008 16:21:07 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:6000945</guid><dc:creator>Wayne Allen</dc:creator><author>Wayne Allen</author><description>&lt;p&gt;The easiest way might be to use session variables or thread local storage. It depends on what your code is trying to do.&lt;/p&gt;
&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=6000945" width="1" height="1"&gt;</description></item><item><title>re: Public Variables In VB.NET Modules</title><link>http://weblogs.asp.net/wallen/archive/2003/10/21/32854.aspx#5992891</link><pubDate>Tue, 18 Mar 2008 09:42:36 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:5992891</guid><dc:creator>Sivabalan</dc:creator><author>Sivabalan</author><description>&lt;p&gt;hi &lt;/p&gt;
&lt;p&gt; i m also facing the same problem(public variable being accessed by all the threads) ...&lt;/p&gt;
&lt;p&gt;have you got any way to solve this problem.&lt;/p&gt;
&lt;p&gt;its driving me crazy&lt;/p&gt;
&lt;p&gt;Thanks in advance&lt;/p&gt;
&lt;p&gt;Sivabalan K&lt;/p&gt;
&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=5992891" width="1" height="1"&gt;</description></item><item><title>re: Public Variables In VB.NET Modules</title><link>http://weblogs.asp.net/wallen/archive/2003/10/21/32854.aspx#1380067</link><pubDate>Tue, 09 Jan 2007 10:11:05 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:1380067</guid><dc:creator>Jorre</dc:creator><author>Jorre</author><description>&lt;p&gt;I don&amp;#39;t beleive this is exactly the same problem as in VB6 (maybe Alex can convince me I am wrong). We had in VB6 this exact same problem only when we declared variables in a module Global the problem does not occur at our site when we use Public in VB6 modules.&lt;/p&gt;
&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=1380067" width="1" height="1"&gt;</description></item><item><title>re: Public Variables In VB.NET Modules</title><link>http://weblogs.asp.net/wallen/archive/2003/10/21/32854.aspx#1349913</link><pubDate>Tue, 02 Jan 2007 09:11:25 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:1349913</guid><dc:creator>chandan bhakuni</dc:creator><author>chandan bhakuni</author><description>&lt;p&gt;thanks&lt;/p&gt;
&lt;p&gt;i was facing the problem of declaring public variables and their scope.. this help provide me to customize my apps.&lt;/p&gt;
&lt;p&gt;chandan bhakuni&lt;/p&gt;
&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=1349913" width="1" height="1"&gt;</description></item><item><title>.NET Constants are Really Constant</title><link>http://weblogs.asp.net/wallen/archive/2003/10/21/32854.aspx#345816</link><pubDate>Mon, 03 Jan 2005 18:47:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:345816</guid><dc:creator>TrackBack</dc:creator><author>TrackBack</author><description>&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=345816" width="1" height="1"&gt;</description></item><item><title>re: Public Variables In VB.NET Modules</title><link>http://weblogs.asp.net/wallen/archive/2003/10/21/32854.aspx#47536</link><pubDate>Sun, 04 Jan 2004 23:36:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:47536</guid><dc:creator>Alex</dc:creator><author>Alex</author><description>Well, I have come across this most disturbing phenomena and must say it is driving me insane. I am trying to create a set of &amp;quot;globally&amp;quot; accessible variables from within a page, and any user controls it contains without having to pass the variables back and forth betweent the calling page and the user controls each time.&lt;br&gt;Any Ideas as to how to make this happen, as using the public keyword seems to automatically make them static no matter what I say and screws up my pages between requests.&lt;br&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=47536" width="1" height="1"&gt;</description></item><item><title>re: Public Variables In VB.NET Modules</title><link>http://weblogs.asp.net/wallen/archive/2003/10/21/32854.aspx#32861</link><pubDate>Wed, 22 Oct 2003 01:39:00 GMT</pubDate><guid isPermaLink="false">c06e2b9d-981a-45b4-a55f-ab0d8bbfdc1c:32861</guid><dc:creator>Paul Wilson</dc:creator><author>Paul Wilson</author><description>This is actually the same behavior VB6 modules had, but apparently most VB6 developers never realized this since they worked primarily with Windows apps that serviced only one user at a time.  I actually had a hard time tracking down an error in VB6 that resulted from this one time that a predecessor had did.  Anyhow, this comes up often in the various forums, so its a rather significant stumbling block in ASP.NET for VB developers.&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=32861" width="1" height="1"&gt;</description></item></channel></rss>