Want to check my theory on References are correct

darbid

Registered User.
Local time
Today, 14:50
Joined
Jun 26, 2008
Messages
1,428
I realise that I should be dealing with this issue with an "installer" but I am trying for second best.

Certain users of my MDB will do some image manipulation. I have built a cut down version of Imagemagick. This has a COM+ object that will require registering and thus referencing.

I do not want to force everyone to have this so here is what I am thinking I should do.

I code my MDB with late binding and do not reference this .dll

1. Question: This would mean the MDB is going to work fine as long as nobody gets to the code that does the image manipulation?

A user can "install" from my MDB the .dll.
This would register the .dll and add a reference to their MDB.

2. Question: Is this the right order? First register then reference, I suppose you must register before there is anything to reference?

This leaves me with the problem of when they get a new version of my MDB. This is simply a copy/replace of the MDB. Thus they will have an unreferenced .dll. (default of my mdb is no reference) I simply check either that the .dll is on their PC or the registry (or both) and then add the reference at startup.

Any comments welcome.
 
i think so

i have an app that uses mappoint. not every user has mappoint

i have a user setting that indicates the user has mappoint. if the user doesnt set this , it doesnt let him get to the mappoint code. if he sets it by error, then getting to the mappoint stuff will crash the app.

---------------
but at the moment, im more bothered about the functionality. i do have it set as a permanent reference. so when i install this on a machine that doesnt have it, the app wont compile. but it still runs ok
 
but at the moment, im more bothered about the functionality. i do have it set as a permanent reference. so when i install this on a machine that doesnt have it, the app wont compile. but it still runs ok
I would have thought the alternative is better. The defult is not referenced. Then for people using this function it is made a reference. I store personal settings for users in an .ini file so I would flag this as true and at start up I would check that it is referenced, if not then reference it.

I am talking 100% theory at the moment as I have not done this yet so I am just wanting to know the pitfalls.

I can use an .exe and the comandline as an alternative, but would prefer to use the COM .dll.
 

Users who are viewing this thread

Back
Top Bottom