Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

MTS - Run Time Error 91

Status
Not open for further replies.

shilp

Programmer
Nov 21, 2001
3
0
0
US
Situation:

Components A and B are in MTS. Both A and B declared transactional...

Component A calls Components B with CreateInstance..
Component B just calls an SP in SQL Server 7.0

In Vb App, create an For loop say 1000 times... create A with either New or CreateObject...and then set it to nothing..

First instance runs fine..
Start another instance, Run time error 91 right away...

Is there any tuning to be done...seems like MTS is unable to create the instance for B inside A..
can anyone help...???
 
Are you passing a blank recordset to method in classB. If yes then create a structure for the recorset and then send it. Another option you can try is build the dll with No compatiblity and then with Binary compatiblity.
This can solve the problem.

Quite a few time s we had to re-install the service pack, recompile the dll and then run the app to solve the problem.
 
Thanks Vinod,

But, we do compile with Binary compatibilty. The class B returns a recordset. In my test case, all the sp did was check login and return a recordset of one row indicating any errors.

I still have the problem. Any pointers would be helpful.

Thanks
 
Check if u have called Setcomplete/Setabort in the rootobject.

Program u'r components A and B such that they are stateless, i.e dont hold any stateful reference.

Try to set the first instance to nothing and again go for a new instance of A.



 
Problem has been solved already.

Thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top