#Xref List
6 messages in this thread
I am looking for a why in which to get a list of reference files,
including any associated path, from a drawing file without going to
graphics. The reason for this is to allow for the "checking out" of
reference files from a server to the local workstation.
Any help in this area would be greatly appreciated.
Gary-
I believe that there was a recent upload to one of the libraries dealing
with just this issue.
I'm really curious about your wish, though. I tried to start a thread a
month or so back, dealing with just that issue; with the advent of reference
files, how do people deal with networked environments, as some leave
everything on the server, and some use a checkout scheme, which complicates
the use of xref's. I was also asking how the various network drawing
management systems deal with this, such as 10CAD, AutoEDMS, and Autobase.
I got a very paltry response.
So, how/why do you work your drawing checkout system? Did you roll your own,
or are you using something off the shelf? What advantage do you see over
leaving everything on a central file server?
Gary and ALL –
I have completed a routine that writes out a batch file that copies all
xrefs to a drive or directory. It uses ssget to make a list of the blocks.
Then I get the block names one-by-one and do a tblsearch on it which
returns an association list. If the insert is an xref, then (cdr (assoc 1
block_list)) will return the directory path. (block_list a variable
containing the result of tblsearch.)
Finally I write that out to a file called xref.bat. The idea was to aide in
archiving a drawing.
One problem! If you xref/attach a block without the full path, allowing the
DOS ACAD=dir1;dir2 environment to find it, there will be no path – only the
block name. So the first advice is to always use the complete path to
externally referenced symbols.
To all: any other ways to do this better??
– Ted Schaefer
I'd like to write a
Ted – Well, if the XREF doesn't have a path, then all you need to do is give
the name of the referenced drawing to (findfile), and it should return the
fully-qualfied path to the file (I think we could rely on the undocumented
aspect that (findfile) will search the library path in the same order that
AutoCAD does when it looks for the drawing file that you specify in the XREF
command). Of course, if the user is aliasing the XREFS in one directory
with different versions of the same drawings in another directory, then you
might have a problem – but then again, that's the nature of the beast, right?
-TonyT.
Tony –
Thanks for the XREF/FINDFILE tip. But of course! I should have thought of
it. You broke the mental log jam.
– Ted Schaefer
Gary:
I just recently uploaded a program which does what you asked for. It reads
the .dwg file directly and lists the menu file (with path), fonts (with
paths), and all XREF's, including any nested XREF's. It can be used to
process a single drawing, or a directory, or a drive, or multiple drives.
The program is called SHOWREFS, and you can find it in Lib 9 as SHREFS.ZIP.
It looks like it might be pretty popular. There are already over 20
downloads in less than 4 days.
Mike Dickason
MD Computer Consulting