Author Topic: EventDrop Capabilities  (Read 3498 times)

0 Members and 1 Guest are viewing this topic.

MacGyver

  • Full Member
  • ***
  • Posts: 85
EventDrop Capabilities
« on: July 23, 2012, 02:05:27 PM »
I have a master in a stencil that I drop in a drawing.  I later update the master in the stencil and drop an instance  (of the updated master) into the same drawing.  Now I have two masters that are almost identical in my document master list.  I only want the most recent version of the master. 

Is it possible to use the event drop command to check if there are previous versions of the master in the drawing.  Ideally, if this happens to be the case, the previous version of the master would be updated with the latest version of the master (in the drawing masters) and the changes pushed to each shape in the drawing that references the master.  This would reduce drawing size as i wouldn't have multiple versions of roughly the same master in the drawing.

I know this is confusing, I'm struggling to explain it clearly but any help would be appreciated.

aledlund

  • Hero Member
  • *****
  • Posts: 1412
Re: EventDrop Capabilities
« Reply #1 on: July 23, 2012, 03:56:37 PM »
As in most things, it's a little more complicated than that. The way it works is the first time you drop a master onto a page, a copy is made and placed in the document stencil, and then a copy of the document stencil is dropped onto the page (the original stays in the doc stencil). From then on every time you go to drop that master into the document, it's really the doc stencil that is dropped. Changing the master in the stencil (assuming the name stays the same) will not add the changes to the document. You have to clear the doc stencil to update the local copy of the master, and that does not change the existing iterations of it in the document.
al

MacGyver

  • Full Member
  • ***
  • Posts: 85
Re: EventDrop Capabilities
« Reply #2 on: July 24, 2012, 12:23:16 PM »
So you are confirming the fact that there is no way to add capabilities to the Eventdrop portion of a master that would check to see if a master already exists in document master list with the same name? Or a way of messaging the user if the master being dropped results in
a copy [being] made and placed in the document stencil, and then a copy of the document stencil is dropped onto the page

aledlund

  • Hero Member
  • *****
  • Posts: 1412
Re: EventDrop Capabilities
« Reply #3 on: July 24, 2012, 02:24:31 PM »
afaik the eventdrop happens when the copy is dropped onto the page, not when it is put into the document stencil. Visio by itself is not going to manage the version control that you want, you'll have to write custom code to do that.The problem is actually larger than that because there is no mechanism to track what documents the individual masters may have been placed in.
al

MacGyver

  • Full Member
  • ***
  • Posts: 85
Re: EventDrop Capabilities
« Reply #4 on: July 26, 2012, 03:11:28 PM »
is there a way to update the document master as to align it with the current master shape in the stencil library so as in the document i would only have one version of the master shape? simply Editing the master in the dwg stencil and inserting the master from the stencil library may match the two versions but when i drop the shape from the stencil library, a second version of the shape is still created in the dwg stencil.

another question...
say in my stencil library I have a master PLUG, my dwg stencil has a master PLUG and PLUG.1 and PLUG.2 with insignificant differences between the three shapes

can i somehow merge these masters so that all shapes referencing any of the three PLUG masters in the dwg, will now reference only 1 master PLUG? Or do i simply need to write a macro to find these shapes, delete each individually, then replace with the most recent version of the shape? this would at least allow me to maintain only one master in the dwg mstr stencil.

aledlund

  • Hero Member
  • *****
  • Posts: 1412
Re: EventDrop Capabilities
« Reply #5 on: July 26, 2012, 07:37:57 PM »
the final step in fact has the root of what you want to do, manage your shapes. You have to ask why you have so many versions of a single shape and how often you want to clean house with them.
al