Author Topic: Get the vla-object of the block loaded in the blockeditor(BEDIT)  (Read 2614 times)

0 Members and 1 Guest are viewing this topic.

Harrie

  • Guest

Get the vla-object of the block loaded in the block editor (BEDIT)
Is this possible?

Regards.

irneb

  • Water Moccasin
  • Posts: 1794
  • ACad R9-2016, Revit Arch 6-2016
Re: Get the vla-object of the block loaded in the blockeditor(BEDIT)
« Reply #1 on: May 29, 2014, 01:35:16 AM »
Unfortunately I don't see any sysvar or ActiveX object which states the block object / -name opened in BEdit. I can't even see if there's anything by which to check if BEdit is active.

So my guess is - nope, not possible.

You could go an redefine the BEdit command so you can obtain the block's name. Then run the undefined ._-BEdit to open it. But that means you'd also need to recreate the dialog and the double-click functionality so it appears to the user as if nothing's changed.
Common sense - the curse in disguise. Because if you have it, you have to live with those that don't.

Lee Mac

  • Seagull
  • Posts: 12914
  • London, England
Re: Get the vla-object of the block loaded in the blockeditor(BEDIT)
« Reply #2 on: May 29, 2014, 05:48:47 PM »
The only way that I see to achieve this is to iterate over the set of objects in the block editor and compare the objects to those found in all blocks defined in the drawing in order to determine which definition is being edited...  :|

owenwengerd

  • Bull Frog
  • Posts: 451
Re: Get the vla-object of the block loaded in the blockeditor(BEDIT)
« Reply #3 on: May 29, 2014, 10:41:32 PM »
In ObjectARX you would use the AcApLongTransactionManager. I don't know if long transactions are exposed via COM, but that's where you would look.