Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Access to public variables defined in Global.asax.vb

Reply
Thread Tools

Access to public variables defined in Global.asax.vb

 
 
=?Utf-8?B?dnZlbms=?=
Guest
Posts: n/a
 
      10-07-2005
Hello:

I have defined public variables in Global.asax.vb that are initialized in
the application_start event.

How do I reference these variables in other ASP forms? For example, if my
variable is goTest, I thought I can reference it as Global.goTest but I see
that I cannot.

Thanks.

venki
 
Reply With Quote
 
 
 
 
Lucas Tam
Guest
Posts: n/a
 
      10-07-2005
"=?Utf-8?B?dnZlbms=?=" <> wrote in
news:A2D54C6D-86CA-44D4-A37A-:

> I have defined public variables in Global.asax.vb that are initialized
> in the application_start event.
>
> How do I reference these variables in other ASP forms? For example, if
> my variable is goTest, I thought I can reference it as Global.goTest
> but I see that I cannot.


Assign them as application variables ... rather than local public
variables.

--
Lucas Tam ()
Please delete "REMOVE" from the e-mail address when replying.

Newmarket Volvo Sucks! http://newmarketvolvo.tripod.com
 
Reply With Quote
 
 
 
 
John Smith
Guest
Posts: n/a
 
      10-10-2005
The variable must be a "public shared" one.

"vvenk" <> schreef in bericht
news:A2D54C6D-86CA-44D4-A37A-...
> Hello:
>
> I have defined public variables in Global.asax.vb that are initialized in
> the application_start event.
>
> How do I reference these variables in other ASP forms? For example, if my
> variable is goTest, I thought I can reference it as Global.goTest but I
> see
> that I cannot.
>
> Thanks.
>
> venki



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
microsoft.public.certification, microsoft.public.cert.exam.mcsa, microsoft.public.cert.exam.mcad, microsoft.public.cert.exam.mcse, microsoft.public.cert.exam.mcsd loyola MCSE 4 11-15-2006 02:40 AM
microsoft.public.certification, microsoft.public.cert.exam.mcsa, microsoft.public.cert.exam.mcad, microsoft.public.cert.exam.mcse, microsoft.public.cert.exam.mcsd loyola Microsoft Certification 3 11-14-2006 05:18 PM
microsoft.public.certification, microsoft.public.cert.exam.mcsa, microsoft.public.cert.exam.mcad, microsoft.public.cert.exam.mcse, microsoft.public.cert.exam.mcsd loyola MCSD 3 11-14-2006 05:18 PM
microsoft.public.certification, microsoft.public.cert.exam.mcsa, microsoft.public.cert.exam.mcad, microsoft.public.cert.exam.mcse, microsoft.public.cert.exam.mcsd realexxams@yahoo.com Microsoft Certification 0 05-10-2006 02:35 PM
microsoft.public.dotnet.faqs,microsoft.public.dotnet.framework,microsoft.public.dotnet.framework.windowsforms,microsoft.public.dotnet.general,microsoft.public.dotnet.languages.vb Charles A. Lackman ASP .Net 1 12-08-2004 07:08 PM



Advertisments