Wrox Programmer Forums
|
VB Components Issues specific to components in VB.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the VB Components section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old November 26th, 2003, 12:22 AM
Authorized User
 
Join Date: Sep 2003
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to balakumar1000
Default VB Comp. deployment in Com+

I want to create a VB Component that needs to be deployed in COM+ and will be used in my ASP pages.
Can anyone help me in telling some guidelines for component creation and deployment. What are the pre-cautions i need to take up.
Thanks for any reply

Balakumar Vijayan
Sr. S/W Engr.
Trivandrum
__________________
Balakumar Vijayan
Sr. S/W Engr.
Trivandrum
 
Old November 26th, 2003, 01:13 AM
Authorized User
 
Join Date: Sep 2003
Posts: 21
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to balakumar1000
Default

For the ActiveX DLL Project, there are few properties one has to set for the class:
Instancing Property
MTSTransactionMode
Persistable

And for the Project, Properties like:
Unattended Execution
Threading Model(Thread per object, Thread pool)
Retained in Memory

Can anyone explain the possible values for these properties and their significance?
 
Old November 28th, 2003, 05:29 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 1,212
Thanks: 0
Thanked 1 Time in 1 Post
Default

I can help you with some general guidance, but you'll have to do a bit of reading to ensure you set the values to suit the requirements of your project. Lets start with the easy ones, 99% of the time you will want these values for a COM+ DLL:
Instancing Property = Multi Use
Persistable = NotPersistable
Unattended Execution = Yes
Retained in Memory = Yes
Threading Model = Apartment

The final one, MTSTransactionMode, is a bit harder to say. As a general guide, if your component will only be doing database reads you should set it to UsesTransactions (but sometimes you may want NoTransactions). If you are doing db writes then you should have RequiresTransaction (but sometimes you may want RequiresNewTransaction). Note that while you're developing the component you may want to set all to NoTransactions because otherwise it really slows down when running in debug mode in the VB IDE.

Do you know about Binary Comaptibility option in Project Properties? If not, make sure to learn about that too, its v important.

Also, if you are going to call the COM+ component from ASP you need to consider the identity under which the component will run. Generally, the default option of 'Interactive User' is not good for ASP. It all depends on the set-up of your system and whether the component will be running on the web server or another server. Also, if its accessing a database, is that db on another server too?

hth
Phil





Similar Threads
Thread Thread Starter Forum Replies Last Post
Need help for VB .Net deployment options pranav_vaidya Visual Studio 2008 0 September 19th, 2008 06:57 AM
Package and Deployment of in VB.NET tact_259 General .NET 7 April 25th, 2007 12:08 AM
VB deployment - uninstalling previous version madhukp VB How-To 1 January 4th, 2006 09:54 AM
VB 6 Application deployment across platform shujath VB How-To 2 March 23rd, 2005 12:59 AM
VB.NET Deployment Handbook billsox Wrox Book Feedback 2 August 28th, 2003 04:03 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.