Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

GetObjectContext fails in VB6 when MTSTransactionMode set

276 views
Skip to first unread message

Gary Howorka

unread,
Sep 1, 1998, 3:00:00 AM9/1/98
to
I created an ActiveX.DLL in VB6 using Transaction server component. In the
code when I attempt to do the following

Dim oMtxContext As ObjectContext
Set oMtxContext = GetObjectContext()

the oMtxContext is set to nothing. I cannot get a reference to
the ObjectContext.

Any ideas. This is a no brainer in ATL/C++ so whats the problem?

George Earl

unread,
Sep 2, 1998, 3:00:00 AM9/2/98
to
Have you the MTS components referenced in the project, and are you trying to
use this in the design-time environment. I'm having the same trouble I
think, i.e. how to run the code at design-time, it seems only to work when
packaged into and running within MTS.

I have posted a question specifically about this, and hopefully I'll get an
answer.

Regards

Gary Howorka wrote in message ...

Jason Phelps

unread,
Sep 3, 1998, 3:00:00 AM9/3/98
to
There is a key you need to add to your registry
in order to debug MTS components using the
Object Context within the VB debugger.

add the following key, no values are necessary:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Transaction Server\Debug

and you will be able to get an ObjectContext other than Nothing.

Jason phelps

Bruce L-C

unread,
Sep 3, 1998, 3:00:00 AM9/3/98
to
I have not been successful getting anything other than nothing from within
the VB6 IDE. I have NT SP4 beta installed. I put in the key you suggested
and rebooted. I set the MTSTransactionMode property to 1 and 3. I have the
compatibility mode set to binary (as the message from VB6 says). I have
tried it both with and without the component being installed in MTS (the
readme suggests not installing it in MTS). My component works if put in MTS
and called from the test program but it fails doing a setcomplete (because
the objectcontext is nothing) if I run it from the debugger (fails both
stepping through and just running it with no breakpoints).

Any ideas?

Bruce L-C

Jason Phelps wrote in message ...

Bob Beauchemin

unread,
Sep 6, 1998, 3:00:00 AM9/6/98
to
Are your components running in an MTS library package (as opposed to
server package)?

Bob Beauchemin
bo...@steptech.com

Bruce L-C wrote in message ...

Ken Kaplan

unread,
Sep 11, 1998, 3:00:00 AM9/11/98
to
I'm having the same problem you are, but I still have the service pack
issue. I'm using SP3, but VB6 claims to require SP4 for MTS...which I can't
find on any MS site.

Do you know where I can get ahold of SP4, beta or otherwise?

Any suggestions appreciated...

Bruce L-C wrote in message ...
>I have not been successful getting anything other than nothing from within

>the VB6 IDE. I have NT SP4 beta installed....

Bruce L-C

unread,
Sep 14, 1998, 3:00:00 AM9/14/98
to
Well, whoever it was that got this working must be on a beta where he is
getting frequent builds. The SP4 beta I have does not support this
(confirmed by MS). So, it is getting close to release time for the SP4
anyway (hopefully within a few weeks). So, I am just not going to worry
about it anymore until I get the real thing.

Bruce L-C

Ken Kaplan wrote in message ...

0 new messages