473,385 Members | 1,983 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Application Object Or Variable!

The following code exists in a Global.asa file:

----------------------------------------------
<%
Set Application("Thing")=Server.CreateObject("THINGDOE R.THINGY")
%>
----------------------------------------------

Will the above code snippet
create a non-object Application variable named "Thing" & place it in
the Contents collection of the Application object?

-----OR------

create an Application object named "Thing" & place it in the
StaticObjects collection of the Application object?

Thanks,

Arpan

Jul 24 '05 #1
2 1314

"Arpan" <ar******@hotmail.com> wrote in message
news:11*********************@f14g2000cwb.googlegro ups.com...
The following code exists in a Global.asa file:

----------------------------------------------
<%
Set Application("Thing")=Server.CreateObject("THINGDOE R.THINGY")
%>
----------------------------------------------

Will the above code snippet
create a non-object Application variable named "Thing" & place it in
the Contents collection of the Application object?

-----OR------

create an Application object named "Thing" & place it in the
StaticObjects collection of the Application object?

Thanks,

Arpan


It will create an application variable and set it to an object. This is not
considered wise unless the object is designed specifically for a
multi-threaded environment.

If you want the object in the staticobjects collection you will need to use
an <object> tag in global.asa to create it (again, make sure it is designed
for this)>

<object id="thing" progid="THINGDOER.THINGY" runat="Server"
scope="Application"></object>

--
Mark Schupp


Jul 25 '05 #2
Thanks Mark :-)

Regards,

Arpan

Jul 26 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Patrick | last post by:
Hi I have the following problem. When starting my asp.net application, i read a encrypted string from a file, decrypt it and want this values to be available in the complete application. they...
4
by: Keith Chadwick | last post by:
I am having some trouble referencing an Application("myVar") variable from within a module.vb file on my ASP.NET site. According to the documentation I should be able to reference...
9
by: William LaMartin | last post by:
I have a problem, mentioned here before, of Session and Application variables disappearing at one site but not at others or on my development computer. The problem is illustrated by an example...
2
by: Joshua Weir | last post by:
Hi, I have setup my asp.net app so that i have one globalobject that contains all information for my application. I am trying to work out the best way to implement the applicationstate object...
7
by: Greg Collins [MVP] | last post by:
Hi, I couldn't find what I was looking for by searching the newsgroup, but perhaps these have already been discussed somewhere. This is a bit long with a lot of interrelated questions. What I've...
20
by: J-T | last post by:
We are working on an asp.net application which is a 3-tier application.I was aksed to create a component which monitors a folder and gets the file and pass them to a class library in our business...
3
by: Daniel Friend | last post by:
I have an application and use custom user controls as plugins. Is there any way to communicate back and forth from control to app. NOTE: The control is not refrenced in the app, it will act as a...
10
by: nutso fasst | last post by:
Hi. Any way to do this from asp page in IIS4? Application.Contents.Remove is IIS 5+. Setting variable to empty string does not remove variable. thx, nf
9
NeoPa
by: NeoPa | last post by:
In VBA (I expect VB would be similar) controlling another Office Application (Automation) can be done using the following steps : Ensure the Reference (VBA Window / Tools / References) has been...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.