Function Syntax: UnReloadDetachSelectedXrefs Version: 1 Date: 18.09.2025 AI+ Description Tool to unload, reload, detach, or change the attachment type (Attach or Overlay) of external references. It shows one list with aligned Name, Type, and Status columns, supports wildcard filtering and multi selection, and uses an Apply loop so you can repeat actions quickly without closing the window. What the user must do - Run XRS or XRUI to open the dialog. For quick all xref actions you may use XU and XR if available in your setup. - In the dialog type a filter pattern using * and ?, click Filter or Clear, select items in the list, choose an action, then click Apply or one of the ALL buttons. Commands - XU unload all xrefs in the current drawing. - XR reload all xrefs in the current drawing. - XRS or XRUI open the dialog for filtering and multi selecting xrefs, then apply actions. Dialog layout and buttons - Filter row edit box plus Filter and Clear to apply or reset wildcard filtering. The list updates while you type. - List one window with columns Name | Type | Status, multi selection enabled, with Select All and Select None helpers. - Operation group Unload with Unload ALL, Reload with Reload ALL, Detach with Detach ALL. - Attachment group Attach with Attach ALL, Overlay with Overlay ALL. - Profiles Save List opens a save dialog for the visible list, Load List reads a saved profile, Apply List applies it. - Bottom row Apply keeps the dialog open, Close, Help shows these notes. Functionalities - Filter xrefs with * and ? case insensitive. The list refreshes in real time. - Multi select and run the chosen operation with Apply while staying in the loop. - One click bulk actions Unload ALL, Reload ALL, Detach ALL, Attach ALL, Overlay ALL. - Profiles Save List writes Name|Type|Status to a text file, Load List loads it, Apply List enforces the saved state. - Preview of changes after loading a list, the Type and Status columns can show current -> target so you see what will change. How it works under the hood - Pure AutoLISP xrefs are discovered from the BLOCK table by flag, no external COM dependency required. - For unload reload and detach the routine calls -XREF with the specific xref name never wildcards. - Changing Attach or Overlay is done by safe detach and re attach, preserving insertion point, scale, rotation, layer, and layout. - Command echo and file dialogs are temporarily adjusted only while actions run and then restored. The window reopens after Apply to keep the loop stable. Safety notes - Detach and Detach ALL permanently remove the reference from the drawing. Reattach if done by mistake. - Actions target only the xrefs that are visible after filtering and the ones you selected when using Apply. Typical workflow - Start XRS or XRUI. - Type a filter such as X_*_Plan?, click Filter, then multi select matches. - Choose Unload, Reload, or Detach or pick Attach or Overlay, click Apply to run, or use the paired ALL buttons for one shot bulk actions. - Click Clear to reset the list or Close to exit. Saved list format - Each line is Name|Type|Status or CSV Name,Type,Status. Example X_Site,Overlay,Loaded. Notes - Default column widths (setq *wName* 35 *wType* 14 *wStat* 18). Adjust these variables at the top of the LISP if you want a different layout.