Author Topic: IAcadBlockReference2 and AcadBlockReference, how to use both  (Read 3068 times)

0 Members and 1 Guest are viewing this topic.

jjs

  • Guest
I have some users on version 2004 of vanilla autocad. I just installed a 2006 trial version of ABS, but I use 2004 for my production stuff. It must have changed my TLB file and now I cannot use AcadBlockReference on my machine. But I need the code to run on both machines. Machine that does not have 2006 installed and one that has both 2004 and 2006 installed. Any suggestions?

JJS

Bob Wahr

  • Guest
Re: IAcadBlockReference2 and AcadBlockReference, how to use both
« Reply #1 on: June 29, 2006, 01:14:26 PM »
you could use acadver to check which version is running

All I can think is to check the registry to see if 2006 is installed and code accordingly. sortof
Code: [Select]
if not boo2k6Loaded then
  Dim objBlkRef as AcadBlockReference
Else
  Dim objBlkRef as IAcadBlockReference2

Bob Wahr

  • Guest
Re: IAcadBlockReference2 and AcadBlockReference, how to use both
« Reply #2 on: June 29, 2006, 01:15:51 PM »
Another thought it try reinstalling 2004 and see if it fixes itself.

Bryco

  • Water Moccasin
  • Posts: 1883
Re: IAcadBlockReference2 and AcadBlockReference, how to use both
« Reply #3 on: June 29, 2006, 02:13:38 PM »
I had the same problem with a trail version.
Deleted the trial version then reloaded 2004 and was fixed.
Like you said, the 2004 reads a 2006 tlb.
I dont have this problem with 2004 and 2006 registered versions on the same machine

jjs

  • Guest
Re: IAcadBlockReference2 and AcadBlockReference, how to use both
« Reply #4 on: July 21, 2006, 10:11:28 AM »
we just ordered 2007 abs, so i can uninstall the 2006 version and get my 2004 fixed back up. Hopefully 2007 should have a completely separate tlb and i can have separate versions.

Bryco

  • Water Moccasin
  • Posts: 1883
Re: IAcadBlockReference2 and AcadBlockReference, how to use both
« Reply #5 on: July 21, 2006, 08:02:41 PM »
JJS, I played a little with  IAcadBlockReference2 and the block versions, it seems like you never have to dim something as a 2 to get the 2 properties. That is, dim it as AcadBlockReference and you still have the properties but not the intellisense.