CADD Manager Code Link!
I have used this program forever. And it is GREAT!
XRP – generate relative paths for XREFs – Xrp2004.lsp – created by Mark McDonough
From the author – “I wrote this for AutoCAD R14 (7 years ago) and I keep waiting for AutoCAD to fully embrace “Xref Relative Pathing”. But even with AutoCAD R2007, one still needs a utility to convert full XREF paths into relative paths. AutoCAD 2004 was the first release that allowed specifying a relative path when first attaching an XREF, it still does not allow automatic conversion of existing full XREF paths into relative paths. Nor is there any support for relative pathing for IMAGES. XRP makes the conversion of full XREF & IMAGE paths into relative paths easy. For AutoCAD R14 – R2006 (not yet tested in R2007, but feel free to give it a try). After loading the lisp file, the command name is XRP.”
See more code at http://www.caddmanager.com/Programming.html