473,412 Members | 2,174 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,412 software developers and data experts.

ASP Classes vs COM

CJM
For the majority of my work, I just use plain ASP. On the rare occasion that
I am doing something intensive that does require user interaction I might
create a COM component (ie where performance gain outweighs the overhead of
COM).

A simple Rule-of-Thumb. I imagine this is fairly common practice... (I hope
it is, at least).

However, I'm curious about VBScript Classes. I would have imagined that if a
page was complex enough to merit defining and creating your own
classes/objects, that COM would be appropriate...

In which case, when and how do people use VBScript Classes?

Thanks

Chris
Jul 19 '05 #1
8 2504
They are useful to encapsulate functionality and provide intellisense for
the functions etc. but they can't be easily persisted in the session state
so their usefulness in that sense is limited.
It's also true that Interdev doesn't give you intellisense for include files
that contain VBScript classes so the usefulness of encapsulating groups of
functions is also reduced by this.
In contrast, Windows Script Components provide all the benefits of COM
components but as a scripted solution. Hence, you can change the component
without recompilation.
I have used them in the past where custom DLL components were not allowed on
the web server and they are very good but severely hampered by their
implementation and lack of development tools that can work with them
properly. Usually, I get a VBScript class working and then move it into a
WSC if I feel they are important enough. A classic example in my case is a
script wrapper for ADO that I have used for some time now. Since a lot of my
ASP is DB based then I use this particular component a lot.

These are just *my* opinions though so don't read too much into them.

Chris.

"CJM" <cj*****@yahoo.co.uk> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
For the majority of my work, I just use plain ASP. On the rare occasion that
I am doing something intensive that does require user interaction I might
create a COM component (ie where performance gain outweighs the overhead of
COM).

A simple Rule-of-Thumb. I imagine this is fairly common practice... (I hope
it is, at least).

However, I'm curious about VBScript Classes. I would have imagined that if a
page was complex enough to merit defining and creating your own
classes/objects, that COM would be appropriate...

In which case, when and how do people use VBScript Classes?

Thanks

Chris

Jul 19 '05 #2
Also, MS did some testing with ASP vs. COM speed of execution and certainly
with IIS 5.0 and above, the script solutions are almost as fast as the VB
compiled solutions although not nearly as fast as C++ components which don't
require the VB runtimes to be loaded up.

Chris.

"CJM" <cj*****@yahoo.co.uk> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
For the majority of my work, I just use plain ASP. On the rare occasion that
I am doing something intensive that does require user interaction I might
create a COM component (ie where performance gain outweighs the overhead of
COM).

A simple Rule-of-Thumb. I imagine this is fairly common practice... (I hope
it is, at least).

However, I'm curious about VBScript Classes. I would have imagined that if a
page was complex enough to merit defining and creating your own
classes/objects, that COM would be appropriate...

In which case, when and how do people use VBScript Classes?

Thanks

Chris

Jul 19 '05 #3
CJM
I remember seeing that paper I think...

Cheers

Chris

"Chris Barber" <ch***@blue-canoe.co.uk.NOSPAM> wrote in message
news:uQ**************@tk2msftngp13.phx.gbl...
Also, MS did some testing with ASP vs. COM speed of execution and certainly with IIS 5.0 and above, the script solutions are almost as fast as the VB
compiled solutions although not nearly as fast as C++ components which don't require the VB runtimes to be loaded up.

Chris.

"CJM" <cj*****@yahoo.co.uk> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
For the majority of my work, I just use plain ASP. On the rare occasion that I am doing something intensive that does require user interaction I might
create a COM component (ie where performance gain outweighs the overhead of COM).

A simple Rule-of-Thumb. I imagine this is fairly common practice... (I hope it is, at least).

However, I'm curious about VBScript Classes. I would have imagined that if a page was complex enough to merit defining and creating your own
classes/objects, that COM would be appropriate...

In which case, when and how do people use VBScript Classes?

Thanks

Chris

Jul 19 '05 #4
Chris Barber wrote:
Also, MS did some testing with ASP vs. COM speed of execution and certainly
with IIS 5.0 and above, the script solutions are almost as fast as the VB
compiled solutions

<snipped>
The script solution was _faster_, especially when there were many users.
See Figure 9 of Microsoft's Nile Benchmarks at
http://msdn.microsoft.com/library/en...asp?frame=true

The full article title is "Architecture Decisions for Dynamic Web
Applications: Performance, Scalability, and Reliability" by Gregory
Leake, Microsoft Corporation, November 2000

Jul 19 '05 #5
That was the one!

Thanks for the link.

Chris.

"Michael D. Kersey" <md******@hal-pc.org> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl...
Chris Barber wrote:
Also, MS did some testing with ASP vs. COM speed of execution and certainly with IIS 5.0 and above, the script solutions are almost as fast as the VB
compiled solutions

<snipped>
The script solution was _faster_, especially when there were many users.
See Figure 9 of Microsoft's Nile Benchmarks at
http://msdn.microsoft.com/library/en...asp?frame=true

The full article title is "Architecture Decisions for Dynamic Web
Applications: Performance, Scalability, and Reliability" by Gregory
Leake, Microsoft Corporation, November 2000
Jul 19 '05 #6
I have played with them, but find that the main reason for going to classes
warrants creating a reusable component. I have yet to see an app where I
felt a VBScript class would be the right option. I am not saying that the
app does not exist, just that I have yet to see one.

--
Gregory A. Beamer
MVP; MCP: +I, SE, SD, DBA

************************************************** ********************
Think Outside the Box!
************************************************** ********************
"CJM" <cj*****@yahoo.co.uk> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
For the majority of my work, I just use plain ASP. On the rare occasion that I am doing something intensive that does require user interaction I might
create a COM component (ie where performance gain outweighs the overhead of COM).

A simple Rule-of-Thumb. I imagine this is fairly common practice... (I hope it is, at least).

However, I'm curious about VBScript Classes. I would have imagined that if a page was complex enough to merit defining and creating your own
classes/objects, that COM would be appropriate...

In which case, when and how do people use VBScript Classes?

Thanks

Chris

Jul 19 '05 #7
Well, using Classes is good stuff when you represent your webware project as
somethign object oriented, say manipulating with web site as with collection
of objects. Nothing hard and saves you thousands hours of work...

ev.
Jul 19 '05 #8
The main thing against ASP classes is that you can't store them in the
Session or Application.

So with that in mind classes are good where you want to encapsulate
functionality in an object-orientated fashion. You can use functions etc to
abstract functionality, but it is procedural rather than object-orientated.

Let's say instead of working with a recordset you want to create an ASP
class that represents a customer, or whatever, which lets you use the
object's properties and methods in a COM-way. It is a half-way house in
that it gives you the object based COM features but without COM
hassle/overhead....but limited to scripts where all logic is on the one page
of course.

How much you use them depends on how much you like to work with objects
rather than recordsets, strings of XML, Request variables etc.

"CJM" <cj*****@yahoo.co.uk> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
For the majority of my work, I just use plain ASP. On the rare occasion that I am doing something intensive that does require user interaction I might
create a COM component (ie where performance gain outweighs the overhead of COM).

A simple Rule-of-Thumb. I imagine this is fairly common practice... (I hope it is, at least).

However, I'm curious about VBScript Classes. I would have imagined that if a page was complex enough to merit defining and creating your own
classes/objects, that COM would be appropriate...

In which case, when and how do people use VBScript Classes?

Thanks

Chris

Jul 19 '05 #9

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

Similar topics

1
by: Bob Rock | last post by:
Hello, in the last few days I've made my first few attempts at creating mixed C++ managed-unmanaged assemblies and looking aftwerwards with ILDASM at what is visible in those assemblies from a...
9
by: Jack | last post by:
Hello I have a library of calculationally intensive classes that is used both by a GUI based authoring application and by a simpler non-interactive rendering application. Both of these...
9
by: Aguilar, James | last post by:
I know that one can define an essentially unlimited number of classes in a file. And one can declare just as many in a header file. However, the question I have is, should I? Suppose that, to...
12
by: Langy | last post by:
Hello I'm fairly new to C++ but have programmed several other languages and found most of c++ fairly easy (so far!). I've come to a tutorial on classes, could someone please tell me why you...
4
by: john townsley | last post by:
do people prefer to design classes for the particular job or for a rangle of tasks they might encounter now and in the future. i am doing some simple win32 apps and picking classes is simple, but...
2
by: joye | last post by:
Hello, My question is how to use C# to call the existing libraries containing unmanaged C++ classes directly, but not use C# or managed C++ wrappers unmanaged C++ classes? Does anyone know how...
18
by: Edward Diener | last post by:
Is the packing alignment of __nogc classes stored as part of the assembly ? I think it must as the compiler, when referencing the assembly, could not know how the original data is packed otherwise....
6
by: ivan.leben | last post by:
I want to write a Mesh class using half-edges. This class uses three other classes: Vertex, HalfEdge and Face. These classes should be linked properly in the process of building up the mesh by...
0
by: ivan.leben | last post by:
I am writing this in a new thread to alert that I found a solution to the problem mentioned here: http://groups.google.com/group/comp.lang.c++/browse_thread/thread/7970afaa089fd5b8 and to avoid...
2
by: Amu | last post by:
i have a dll ( template class) ready which is written in VC++6. But presently i need to inherit its classes into my new C#.net project.so if there is some better solution with u then please give me...
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...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

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.