Function Syntax: Command Version: 1.0 Date: N/A id: ibb7q2 short_description: | SEO Description 🚀 InsertBlockFilterScale is an AutoCAD and Civil 3D AutoLISP block insertion utility for filtering, previewing, copying, and inserting existing DWG block definitions. It provides a DCL-based block browser with wildcard filtering, multi-select support, block preview, scale input, rotation input, and persistent settings. The main benefit is faster block insertion, easier CAD symbol placement, better DWG block management, and improved AutoCAD Civil 3D drafting productivity. command: | Main Command and Loading Method 🧰 Load the LISP file with APPLOAD or another AutoCAD AutoLISP loading method. Run InsertBlockFilterScale to open the block filter, preview, scale, and insertion dialog. The implemented command function is c:InsertBlockFilterScale. Run IBB-DEBUG to print the internal debug log to the AutoCAD command line. The target platform is AutoCAD and Civil 3D with Visual LISP COM support. description: | Detailed Description 📘 This AutoLISP routine scans the active drawing block table and displays insertable local block definitions in a generated DCL dialog. 🔍 The tool excludes anonymous blocks, external reference blocks, and pipe-named xref blocks so users work with normal local block definitions. 🧩 The user can filter block names, select one or multiple blocks, preview the current block definition, and define a scale and rotation before insertion. 📍 For each selected block, the routine prompts for an insertion point and inserts the block into model space using vla-insertblock. 🧭 The command transforms the picked UCS point to WCS and adjusts the insertion rotation by the current UCS angle. This is useful for AutoCAD block libraries, Civil 3D production drawings, standard symbol placement, detail insertion, CAD cleanup, and DWG drafting automation. helper_function: | Helper Logic 🚀 Command entry point - c:InsertBlockFilterScale loads settings, builds the block list, writes the temporary DCL file, opens the dialog, and processes insert or copy actions. 🔍 Block filter engine - ibb:filter supports normal text filters, wildcard patterns with * and ?, and comma-based matching through wcmatch. 📌 Block table scanner - the routine reads vla-get-blocks and skips anonymous, xref, and pipe-named block definitions. 📐 Preview bounding box logic - ibb:block-bbox calculates preview extents from block definition entities. 🎨 DCL preview renderer - ibb:preview-block and ibb:draw-entity draw simplified geometry with start_image, fill_image, vector_image, and end_image. 🔢 Multi-select helpers - ibb:parse-sel, ibb:sel-names-from-raw, and ibb:restore-sel preserve selected block names during filtering. 📋 Clipboard helper - ibb:copy-to-clipboard uses htmlfile COM, PowerShell Set-Clipboard, and clip.exe fallback. 📍 UCS-aware insertion - ibb:do-insert transforms the point with trans and inserts the block with vla-insertblock. 🔐 Settings persistence - ibb:cfg-read, ibb:cfg-write, and ibb:save store filter, scale, rotation, selected names, and dialog position. functionalities: | Functionalities 🚀 Open a block browser - launches a compact DCL interface for searching and inserting blocks from the active drawing. 🔍 Filter block names - quickly finds block definitions using plain text or wildcard patterns. 🧩 Preview selected block - displays a simplified geometry preview before insertion. 🔢 Insert multiple blocks - supports multi-select and prompts for an insertion point for each selected block name. 📐 Apply scale and rotation - uses user-entered scale and rotation values for inserted block references. 🧭 Use current UCS orientation - converts the picked point to WCS and accounts for UCS rotation. 📋 Copy block names - copies selected block names to the Windows clipboard as a semicolon-separated list. 🔐 Save workflow settings - remembers filter, scale, rotation, selected names, and dialog location. 🧰 Debug diagnostics - prints internal log messages with IBB-DEBUG. result: | Final Result ✅ The final result is a productivity-focused AutoCAD and Civil 3D block insertion tool for searching, previewing, copying, and inserting local block definitions. It reduces repetitive block browsing, improves CAD symbol placement, supports DWG block library workflows, and makes drafting faster and more controlled. additional_info: | Important Notes and Limitations 🟧 Blocks are inserted into ModelSpace through vla-get-modelspace. 📐 The entered scale is applied to X and Y, while Z scale is fixed at 1.0. 🔍 Anonymous blocks, xref block definitions, and pipe-named reference blocks are skipped intentionally. 🎨 The DCL image preview is simplified and does not replace AutoCAD native graphics display. 🏷️ The code does not include a custom block attribute editing workflow after insertion. 🔐 Settings are stored in %APPDATA%\InsertBlockFilterScale.cfg or the AutoCAD temp folder fallback.