Storing an OCX in a table then registering it

R

Ricardo

I am using the Microsoft Common dialog control v6.0 in a database
(COMDLG32.ocx) and have found that some users do not have this OCX file on
their PC so I have to copy it to \windows\system32 then run regsvr32 to
register it.....I would like to automate this within the app.
So, I created a table and can insert the control in the table and my code
can run regsvr32 but how do I actually copy the file from the table to that
directory on the PC? Is there another way to store a file within the database
so it can be copied to the PC?
 
R

Ron Weiner

Ricardo

If I were you I would "loose" the MS Common dialog Control and use the all
API solution described here:

http://www.mvps.org/access/api/api0001.htm

It works 100% of the time, there are no versioning problems, and will
alleviate you from the angst of having to store files, copy files, and make
changes to the users registry. In short it is the preferred solution for MS
Access file Open/Save.

Ron W
www.WorksRite.com
 
P

Paul Overway

You're using circular logic. The reason I say that is you probably have a
reference set to the control in your app, but if it isn't installed your app
will be broken because of the missing reference and therefore unable to
install the OCX. The OCX needs to be installed by a proper installer
OR...and this is the better solution...don't use the OCX at all, but use an
API function instead.
 
N

nelsonsoft

As another option you can take a look at FilePush as www.nssdd.com. It
will push the file out and register it on the remote workstation using
your user rights. So if your end user does not have rights to register
controls you can still do so remotely.

Gil
 
R

Ricardo

Ron, brilliant thank you.


Ron Weiner said:
Ricardo

If I were you I would "loose" the MS Common dialog Control and use the all
API solution described here:

http://www.mvps.org/access/api/api0001.htm

It works 100% of the time, there are no versioning problems, and will
alleviate you from the angst of having to store files, copy files, and make
changes to the users registry. In short it is the preferred solution for MS
Access file Open/Save.

Ron W
www.WorksRite.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top