Rename XREFs in multiple dwgs

Okay,

So after watching @jacob.small’s awesome video and working a bit I believe I have a solution. This script will go through a list of “sheet drawings” in a selected file folder directory and detach all of the xrefs from the drawings. Then, the script will rename all of the xref drawings in an xref folder with a project number. Then, the script will attach all of the xref drawings in the xref folder back to the “sheet drawings”.

It has to be done in that order or it seems to break :sweat_smile: I can’t seem to get a value from “xgraph.node.out(x)” to detach xrefs if they become unreferenced. So they have to be renamed after the detach step. Not sure how else the xref could be selected to be detached if they become unreferenced, maybe the block table record? Not quite sure I’m new to all this :sweat_smile:


XrefUpdates.dyn (11.2 KB)

1 Like