Find and set references at runtime

R

rezafloyd

Dear experts,
I want to write a VBA code in Excel to connect to Autocad. It's a
simple task at design time. But if my code runs at another system with
different version of Autocad it fails.
What I need is a procedure to find all available Autocad references in
the system and set the reference to newest one.
Best regards
Reza
 
T

Tom Ogilvy

http://support.microsoft.com/?id=160647
XL97: How to Programmatically Create a Reference

shows how to create a reference

You can use late binding to work with autocad without creating a reference
(which is the usual approach recommended)

http://support.microsoft.com/default.aspx?scid=kb;EN-US;244167
INFO: Writing Automation Clients for Multiple Office Versions

http://support.microsoft.com/default.aspx?scid=kb;en-us;245115
INFO: Using Early Binding and Late Binding in Automation

http://support.microsoft.com/default.aspx?scid=kb;en-us;247579
INFO: Use DISPID Binding to Automate Office Applications Whenever Possible

http://support.microsoft.com/default.aspx?scid=kb;en-us;319832&Product=xlw
INFO: Error or Unexpected Behavior with Office Automation When You Use Early
Binding in Visual Basic
 

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