can not refernce CommonDialog component

K

ken

can not refernce CommonDialog component

Hi All,
I use window98 / XP develop officeXP VBA programmming, and I found if I
havn't install VB or VS in this computer, I can't refer the component
CommonDialog when I code VBA program.
Any one should give me idea how to solve it?

thx
 
L

Lars-Eric Gisslén

Ken,

The common dialogs are located in the comdlg32.dll in the System directory.
I use the comdlg32.dll directly from my VBA programs but I can't share any
code as it's in the office and I'm on vacation. I'm almost sure you can find
VB code to do this if you if you search on Google.

Regards,
Lars-Eric
 
L

Lars-Eric Gisslén

Ken,

Then you are using an ActiveX component that you have no license to. That's
the poblem with many ActiveX interfaces (to the underlying Windows DLL's)
and VBA.

I would recommend using the code in the link Cheryl provided you with. This
is something you get fooled with if you have VB installed on your machine.
With VB there comes a number of licensed ActiveX controls that you may use
in VBA. If those ActiveX components are not on the target machine and you
tries to copy them there you will face the same problem. No license file on
the target machine. That's why I prefer to use Win API calls instead of
relying on ActiveX components.

Regards,
Lars-Eric
 

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