C3D-0174 · READ-ONLY: the land lot line annotation on the map [LL-TEXT-2] done
Searches for LAND LOT text excluding title block attribute definitions and the legend, so the map annotation itself is reported with its entity type, space, layer, exact string, position, height and rotation. No changes.
C# payload
// READ-ONLY. Find any text saying LAND LOT LINE (approximate or otherwise) - what it is, where it
// sits, its layer, height and rotation. Searched across model space, every layout and every block
// definition. Nothing is modified.
var bt = (BlockTable)Tx.GetObject(Db.BlockTableId, OpenMode.ForRead);
Log("drawing: " + Db.Filename);
int hits = 0;
foreach (ObjectId btrId in bt) {
var btr = (BlockTableRecord)Tx.GetObject(btrId, OpenMode.ForRead);
foreach (ObjectId id in btr) {
Autodesk.AutoCAD.DatabaseServices.DBObject o;
try { o = Tx.GetObject(id, OpenMode.ForRead); } catch { continue; }
string s = null;
var mt = o as MText; if (mt != null) s = mt.Contents;
var dt = o as DBText; if (dt != null) s = dt.TextString;
if (s == null) continue;
string u = s.ToUpper();
if (u.IndexOf("LAND LOT") < 0) continue;
if (o is AttributeDefinition) continue; // title block tags, not the map annotation
if (btr.Name.ToUpper().IndexOf("LEGEND") >= 0) continue;
hits++;
var ent = (Autodesk.AutoCAD.DatabaseServices.Entity)o;
Log("");
Log("[" + o.Handle + "] " + o.GetType().Name + " in " + btr.Name + " layer=" + ent.Layer);
Log(" \"" + s + "\"");
if (mt != null)
Log(String.Format(" at {0:F3},{1:F3} h={2:F3} rot={3:F2} width={4:F3}",
mt.Location.X, mt.Location.Y, mt.TextHeight, mt.Rotation*180.0/Math.PI, mt.Width));
if (dt != null)
Log(String.Format(" at {0:F3},{1:F3} h={2:F3} rot={3:F2}",
dt.Position.X, dt.Position.Y, dt.Height, dt.Rotation*180.0/Math.PI));
}
}
Log("");
Log("land-lot text found: " + hits);
Log("");
Log("=== layers whose name mentions LAND LOT ===");
var lt = (LayerTable)Tx.GetObject(Db.LayerTableId, OpenMode.ForRead);
foreach (ObjectId lid in lt) {
var l = (LayerTableRecord)Tx.GetObject(lid, OpenMode.ForRead);
if (l.Name.ToUpper().IndexOf("LAND LOT") < 0 && l.Name.ToUpper().IndexOf("LANDLOT") < 0) continue;
Log(" " + l.Name + " off=" + l.IsOff + " frozen=" + l.IsFrozen + " color=" + l.Color);
}
Result
Log
drawing: C:\Users\sanja\OneDrive\_SurveyDisco\260613 - 5030 E Lake Pkwy, Stockbridge, GA 30281, USA\260612-C-Store Sewer As-Built.dwg [143DE] DBText in A$C3840e5d8 layer=BLOCK_TB2 "LAND LOT: 230" at -127.320,-163.696 h=4.667 rot=0.00 [1452C] MText in A$C3840e5d8 layer=SS-BOUNDARY ANGEL "IPF IRON PIN FOUND \PIPS IRON PIN SET\PR/W RIGHT OF WAY\PRWM RIGHT OF WAY MARKER \PMAG MAGNETIC \PPOB POINT OF BEGINNING\PPOB POINT OF COMMENCEMENT\PB/L BUILDING LINE \PD.E. DRAINAGE EASEMENT\PN/F NOW OR FORMERLY \PL.L. LAND LOT\PPP POWER POLE \P DROP INLET\P WATER VALVE\P MANHOLE\P FIRE HYDRANT\P ELELVATION POINT\P PROPERTY CORNER" at -470.137,-104.214 h=4.000 rot=0.00 width=107.530 land-lot text found: 2 === layers whose name mentions LAND LOT === SS-BOUNDARY LAND LOT off=False frozen=True color=cyan
Notes
What worked, what didn't, job-specific gotchas — flagged notes feed the recipes.
No notes yet.