reference file search tool

Status
Not open for further replies.

bwiding

Usenet Archive
Joined
Nov 28, 2001
Messages
1
Reaction score
0
Does anyone know of a way to search a group of files to see if a certain file is referenced into any of them ? If I make a change to a certain file I'd like to be able to search for any occurrence of that file within other files.
 
Brian,

What I do is I usually run our RefUtil utility program from the command prompt and specify some 'magic' arguments such as the following:

refutil.exe -hh *.dgn

This lists all the master filenames followed by their reference file attachments...the double-h argument will format the output such that each line of output will have a syntax such as:

masterfile|referencefile
masterfile|referencefile
masterfile|referencefile

I can either dump the output to a file, or I can pipe the output to the DOS FIND command to pick out just the ones I'm interested in:

refutil.exe -hh *.dgn | FIND "uniqueRefFileName"

All the masterfiles are listed before the '|'.

Hope this helps.
(refutil is available at our website as part of the TIMS3Lite package...it hasn't been updated in a while, so you may need to send an email to ask for an updated version that hasn't expired.)

Gary
TIMS3 Tech Team
TIMS3 Document Management Product, www.tims3.com

"bwiding" wrote:

Does anyone know of a way to search a group of files to see if a certain file is referenced into any of them ? If I make a change to a certain file I'd like to be able to search for any occurrence of that file within other files.
 
Hi Brian,
If you'd like a report that reads:

p:\12345\cad\axyzcp02.s01,axyzcp02.dgn,p:\12345\cad\axyzcp02.dgn p:\12345\cad\axyzcp02.s01,borxyz01.dgn,p:\12345\cad\borxyz01.dgn p:\12345\cad\axyzcp03.s01,axyzcp03.dgn,<---File Not Found p:\12345\cad\axyzcp03.s01,axyzcp03.dgn,<---File Not Found p:\12345\cad\axyzcp03.s01,borxyz01.dgn,p:\12345\cad\borxyz01.dgn p:\12345\cad\axyzcp03.s01,borxyz01.dgn,p:\12345\cad\borxyz01.dgn p:\12345\cad\axyzfp02.s01,axyzfp02.dgn,p:\12345\cad\axyzfp02.dgn p:\12345\cad\axyzfp02.s01,borxyz01.dgn,p:\12345\cad\borxyz01.dgn p:\12345\cad\axyzfp03.s01,axyzfp03.dgn,<---File Not Found p:\12345\cad\axyzfp03.s01,axyzfp03.dgn,<---File Not Found p:\12345\cad\axyzfp03.s01,axyzfp03.dgn,<---File Not Found p:\12345\cad\axyzfp03.s01,borxyz01.dgn,p:\12345\cad\borxyz01.dgn p:\12345\cad\axyzfp03.s01,borxyz01.dgn,p:\12345\cad\borxyz01.dgn p:\12345\cad\axyzfp03.s01,borxyz01.dgn,p:\12345\cad\borxyz01.dgn

which you can import into a spreadsheet and then sort, you can use the NYC TMC's macro dgndoc.ba. The format of the file is:

main_file_1.dgn, ref_file_1.dgn, <path>ref_file_1.dgn
main_file_1.dgn, ref_file_2.dgn, <path>ref_file_2.dgn
main_file_2.dgn, ref_file_1.dgn, <path>ref_file_1.dgn
main_file_2.dgn, ref_file_2.dgn, <path>ref_file_2.dgn
main_file_2.dgn, ref_file_3.dgn, <path>ref_file_3.dgn
etc.

When a reference file is missing, the macro indicates "<---File Not Found" instead of the path and ref file name. This alone is worth its weight in gold.

This is only one feature of dgndoc.ba; it can also create a report that shows:
-Active file: file name and dimension (2D or 3D).
-Active file: levels off/levels on, or whichever is shorter (think about it).
-Active file: cell names, including which are shared, and how many orphan cells.
-Active file: fonts.
-Active file: global origin.
-Active file: level symbology.
-Active file: level usage (which levels actually contain elements).
-Active file: line styles and line codes.
-Active file: working units.
-Reference files: full name.
-Reference files: attach name (shows configuration variables).
-Reference files: logical name.
-Reference files: description.
-Reference files: scale (ok, needs some work: integer:1 is ok, 1:integer is crummy).
-Reference files: display off/on status.
-Reference files: locate off/on status.
-Reference files: levels off/levels on, or whichever is shorter (think about it).
-Reference files: level symbology.

And if you act within the next half hour, I'll throw in:
-The ability to handle huge DGN files.
-The ability to "remember" settings during the MicroStation session.
-The full command-line list (macro dgndoc /short /exclude /cfgvar /single for example, 25 switches altogether)
-The handy documentation in PDF format.

If you don't want to open each file manually and press the up arrow to re-run the macro, you'll need a way to run the macro in all your design files. If you're a Select Subscriber, you can download Design File Processor (filepro.ma) from the Bentley site.

The price for dgndoc.ba is 100% free, so you won't need any purchase orders. If you really like the macro and feel guilty using it, please make a nice donation (in your name) to one of the September 11th charities, or maybe to a charity that's been neglected because of the all the donations to the September 11th charities...

NOTE: Works with V7 (J) and prior (SE, 95) only!

I'll e-mail it to you or anyone else that wants it (pls. e-mail me ).

HTH,
Simon

bwiding wrote:
Does anyone know of a way to search a group of files to see if a certain file is referenced into any of them ? If I make a change to a certain file I'd like to be able to search for any occurrence of that file within other files.
 
Status
Not open for further replies.

Latest threads

Back
Top