Access to ASP objects from VB6 dll

Posted on 2003-02-23
Medium Priority
Last Modified: 2010-05-18
I'm adding a dll created with VB6 to my ASP application and need to access the Active Server Page intrinsic objects 'Application' and 'Session' from within the dll. I want my ASP application to be compatible with everything from PWS running on Windows 95 to IIS 5 running on Windows 2000 and so far it is. My development environment is Windows 2000 Pro.

I'm concerned that creating the dll with a reference to either MTS or COM+ will make my application incompatible with some web server installations because I know from experience that PWS and IIS are often installed without MTS. However, I keep reading that using ASPTypeLibrary.ScriptingContext in an OnStartPage event to get the Object Context is not a good thing.

Also, some references state that the OnStartPage event is triggered at the beginning of the ASP but other references state that it is triggered when the component is created from within the ASP script.

I want to keep the application simple to install and certainly don't want to force the installer to understand how to create MTS packages, etc.

My questions:
1. Is using ASPTypeLibrary.ScriptingContext in an OnStartPage event to get the Object Context really a bad idea?

2. Exactly when is the OnStartPage event triggered?

3. If I reference MTS or COM+ does the dll have to be registered in MTS to function. Also, if I compile the dll on Windows 2000 using COM+ would it work on another OS like NT4 or Windows 95?
Question by:teddro
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2

Accepted Solution

Valliappan AN earned 380 total points
ID: 8006372

Author Comment

ID: 8018225
Thanks valli an. These are good articles. I haven't read it all yet but what I need to know may be in there.

I'd like to comment on the lack of responses when I post questions on EE. I don't know if it is the nature of my questions or what but this one is typical. Two days after posting I have one response (a good one though).

Take this question(s) for example. I would think that any experienced ASP/VB programmer would know the exact answers 'off the top of their heads'.

Author Comment

ID: 8019435
Well, i read everything at both links and they give lots of information on using ScriptingContext to get Object Context for accessing ASP objects, like Session and Application. Both articles admit this is a legacy method from the IIS 3 days, but no information on using MTS/COM+.


Expert Comment

by:Valliappan AN
ID: 8022500
I think you can have a read over here and the links over there:
(A lot of info on MTS and COM+)

and also this:
(About MTS and ASP)


Expert Comment

by:Valliappan AN
ID: 8022517

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you ever needed to get an ASP script to wait for a while? I have, just to let something else happen. Or in my case, to allow other stuff to happen while I was murdering my MySQL database with an update. The Original Issue This was written…
This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
In this video we outline the Physical Segments view of NetCrunch network monitor. By following this brief how-to video, you will be able to learn how NetCrunch visualizes your network, how granular is the information collected, as well as where to f…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…
Suggested Courses

764 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question