← Inbox

C3D-0237 · 260612 Springdale: verify SS_BLOCK_11X17 after the right-shift done

READ-ONLY. Confirms where every entity landed and whether anything ran past the sheet edge into positive X.

Script file
C3D-0237.cs
Target
260612-Springdale Sanitary Sewer Extension As-Built 60.dwg · model space
Author
claude
Approved
yes · auto-auth
Timeout
60s

C# payload

// READ-ONLY: everything inside the SS_BLOCK_11X17 definition, with each entity's extents,
// so the title-block cluster can be identified by position before anything is moved.
var bt = (BlockTable)Tx.GetObject(Db.BlockTableId, OpenMode.ForRead);
if (!bt.Has("SS_BLOCK_11X17")) { Log("SS_BLOCK_11X17 not found"); return; }
var btr = (BlockTableRecord)Tx.GetObject(bt["SS_BLOCK_11X17"], OpenMode.ForRead);
Log("=== SS_BLOCK_11X17 contents ===");
Log("origin/base point: " + btr.Origin.ToString());

double gxmin=1e30, gymin=1e30, gxmax=-1e30, gymax=-1e30;
int n = 0;
foreach (ObjectId id in btr) {
    Autodesk.AutoCAD.DatabaseServices.DBObject o;
    try { o = Tx.GetObject(id, OpenMode.ForRead); } catch { continue; }
    var ent = o as Autodesk.AutoCAD.DatabaseServices.Entity;
    if (ent == null) continue;
    n++;
    double xmin=0, ymin=0, xmax=0, ymax=0;
    bool haveExt = false;
    try {
        var e = ent.GeometricExtents;
        xmin=e.MinPoint.X; ymin=e.MinPoint.Y; xmax=e.MaxPoint.X; ymax=e.MaxPoint.Y;
        haveExt = true;
        if (xmin<gxmin) gxmin=xmin; if (ymin<gymin) gymin=ymin;
        if (xmax>gxmax) gxmax=xmax; if (ymax>gymax) gymax=ymax;
    } catch { }
    string extra = "";
    var ad = ent as AttributeDefinition;
    if (ad != null) extra = string.Format(" TAG={0} prompt=\"{1}\" default=\"{2}\" pos=({3:F3},{4:F3}) h={5:F3}",
        ad.Tag, ad.Prompt, ad.TextString, ad.Position.X, ad.Position.Y, ad.Height);
    var mt = ent as MText;
    if (mt != null) extra = string.Format(" \"{0}\" at ({1:F3},{2:F3}) h={3:F3}",
        mt.Contents.Replace("\n", " ").Substring(0, Math.Min(45, mt.Contents.Length)), mt.Location.X, mt.Location.Y, mt.TextHeight);
    var dt = ent as DBText;
    if (dt != null) extra = string.Format(" \"{0}\" at ({1:F3},{2:F3}) h={3:F3}",
        dt.TextString, dt.Position.X, dt.Position.Y, dt.Height);
    var ln = ent as Line;
    if (ln != null) extra = string.Format(" ({0:F3},{1:F3})->({2:F3},{3:F3})",
        ln.StartPoint.X, ln.StartPoint.Y, ln.EndPoint.X, ln.EndPoint.Y);

    Log(string.Format("[{0}] {1,-20} layer={2,-18} ext=({3:F3},{4:F3})-({5:F3},{6:F3}){7}",
        ent.Handle, ent.GetType().Name, ent.Layer,
        haveExt?xmin:0, haveExt?ymin:0, haveExt?xmax:0, haveExt?ymax:0, extra));
}
Log("");
Log(string.Format("entities={0}   BLOCK EXTENTS=({1:F3},{2:F3})-({3:F3},{4:F3})  size {5:F3} x {6:F3}",
    n, gxmin, gymin, gxmax, gymax, gxmax-gxmin, gymax-gymin));

Result

Status
success
Drawing file
C:\Users\sanja\OneDrive\_SurveyDisco\260613 - 5030 E Lake Pkwy, Stockbridge, GA 30281, USA\260612-Springdale Sanitary Sewer Extension As-Built 60 wPROFILE.dwg
Message
Executed C3D-0237 (0 entities touched).
Entities
Duration
349 ms
Civil 3D
25.0.0.0

Log

=== SS_BLOCK_11X17 contents ===
origin/base point: (0,0,0)
[23391] Viewport             layer=BLOCK_TB2          ext=(-21.461,0.043)-(-0.043,16.434)
[23394] Line                 layer=BLOCK_TB2          ext=(11.215,13.546)-(11.215,15.324) (11.215,13.546)->(11.215,15.324)
[23395] Line                 layer=BLOCK_TB2          ext=(-21.461,16.434)-(-0.043,16.434) (-21.461,16.434)->(-0.043,16.434)
[23396] Line                 layer=BLOCK_TB2          ext=(-21.509,16.477)-(0.000,16.477) (-21.509,16.477)->(0.000,16.477)
[23397] MText                layer=BLOCK_TB2          ext=(-3.785,15.678)-(-0.202,16.048) "ALL MATTERS OF TITLE ARE EXCEPTED. THIS PLAT " at (-3.785,16.048) h=0.085
[23398] Line                 layer=BLOCK_TB2          ext=(-3.898,15.554)-(-3.898,16.213) (-3.898,16.213)->(-3.898,15.554)
[23399] Line                 layer=BLOCK_TB2          ext=(-10.200,15.283)-(-2.456,15.284) (-10.200,15.284)->(-2.456,15.283)
[2339A] Line                 layer=BLOCK_TB2          ext=(-10.200,15.013)-(-2.456,15.014) (-10.200,15.014)->(-2.456,15.013)
[2339B] Line                 layer=BLOCK_TB2          ext=(-10.200,14.743)-(-2.456,14.745) (-10.200,14.745)->(-2.456,14.743)
[2339C] Line                 layer=BLOCK_TB2          ext=(-10.200,14.473)-(-2.456,14.475) (-10.200,14.475)->(-2.456,14.473)
[2339D] Line                 layer=BLOCK_TB2          ext=(-10.200,15.554)-(-2.582,15.554) (-10.200,15.554)->(-2.582,15.554)
[2339E] DBText               layer=BLOCK_TB2          ext=(-5.097,14.811)-(-3.616,14.928) "SCALE: GRAPHIC" at (-5.097,14.811) h=0.117
[2339F] Line                 layer=BLOCK_TB2          ext=(-7.661,14.474)-(-7.661,15.284) (-7.661,15.284)->(-7.661,14.474)
[233A0] Line                 layer=BLOCK_TB2          ext=(-2.582,15.554)-(-0.043,15.554) (-2.582,15.554)->(-0.043,15.554)
[233A1] Line                 layer=BLOCK_TB2          ext=(-10.200,16.213)-(-0.045,16.213) (-10.200,16.213)->(-0.045,16.213)
[233A2] DBText               layer=BLOCK_TB2          ext=(-10.159,16.085)-(-9.250,16.162) "PREPARED FOR:" at (-10.159,16.085) h=0.076
[233A3] Line                 layer=BLOCK_TB2          ext=(-5.551,14.474)-(-5.550,15.284) (-5.550,15.284)->(-5.551,14.474)
[233E1] Line                 layer=BLOCK_TB2          ext=(-4.110,16.401)-(-4.110,16.434) (-4.110,16.434)->(-4.110,16.401)
[233E3] Line                 layer=BLOCK_TB2          ext=(-10.200,13.546)-(-10.200,16.213) (-10.200,16.213)->(-10.200,13.546)
[233E4] Line                 layer=BLOCK_TB2          ext=(-2.456,13.546)-(-2.456,15.554) (-2.456,15.554)->(-2.456,13.546)
[233E5] Line                 layer=BLOCK_TB2          ext=(-10.200,13.546)-(11.217,13.546) (-10.200,13.546)->(11.217,13.546)
[233E6] Line                 layer=BLOCK_TB2          ext=(-10.200,16.213)-(-0.045,16.213) (-0.045,16.213)->(-10.200,16.213)
[233E7] Line                 layer=BLOCK_TB2          ext=(0.000,0.000)-(0.000,6.883) (0.000,0.000)->(0.000,6.883)
[233E8] Line                 layer=BLOCK_TB2          ext=(-0.043,0.043)-(-0.043,16.434) (-0.043,0.043)->(-0.043,16.434)
[233E9] Line                 layer=BLOCK_TB2          ext=(-21.509,0.000)-(0.000,0.000) (-21.509,0.000)->(0.000,0.000)
[233EA] Line                 layer=BLOCK_TB2          ext=(-21.509,0.000)-(-21.509,16.477) (-21.509,16.477)->(-21.509,0.000)
[233EB] DBText               layer=BLOCK_TB2          ext=(-8.509,14.101)-(-4.128,14.338) "SAWHNEY & ASSOCIATES" at (-8.543,14.101) h=0.238
[233EC] DBText               layer=BLOCK_TB2          ext=(-8.114,13.881)-(-6.520,13.986) "523 HASTINGS WAY" at (-8.114,13.881) h=0.106
[233ED] DBText               layer=BLOCK_TB2          ext=(-6.352,13.868)-(-4.523,13.974) "JONESBORO GA 30238" at (-6.352,13.868) h=0.106
[233EE] DBText               layer=BLOCK_TB2          ext=(-7.221,13.711)-(-5.874,13.843) "PH.# (678)478-6857" at (-7.228,13.738) h=0.081
[233EF] Line                 layer=BLOCK_TB2          ext=(-3.107,13.546)-(-3.106,14.474) (-3.106,14.474)->(-3.107,13.546)
[233F0] Line                 layer=BLOCK_TB2          ext=(-0.000,6.883)-(-0.000,13.765) (-0.000,6.883)->(-0.000,13.765)
[233F1] Line                 layer=BLOCK_TB2          ext=(-0.000,13.765)-(0.000,16.477) (-0.000,13.765)->(0.000,16.477)
[233F3] AttributeDefinition  layer=BLOCK_TB2          ext=(0.000,0.000)-(0.000,0.000) "JOB NO.: 251002" at (-5.099,14.567) h=0.117
[233F4] AttributeDefinition  layer=BLOCK_TB2          ext=(0.000,0.000)-(0.000,0.000) "SITE_ADDRESS" at (-10.137,15.373) h=0.117
[233F5] AttributeDefinition  layer=BLOCK_TB2          ext=(0.000,0.000)-(0.000,0.000) "REF DB xxx Page xxx" at (-10.134,14.554) h=0.117
[233F6] AttributeDefinition  layer=BLOCK_TB2          ext=(0.000,0.000)-(0.000,0.000) "LAND LOT: ###" at (-7.625,15.104) h=0.117
[233F7] AttributeDefinition  layer=BLOCK_TB2          ext=(0.000,0.000)-(0.000,0.000) "DISTRICT: #TH" at (-7.622,14.838) h=0.117
[233F8] AttributeDefinition  layer=BLOCK_TB2          ext=(0.000,0.000)-(0.000,0.000) "COUNTY: CLAYCO" at (-7.629,14.554) h=0.117
[233F9] AttributeDefinition  layer=BLOCK_TB2          ext=(0.000,0.000)-(0.000,0.000) "DATE: 10/16/25" at (-5.075,15.093) h=0.117
[233FA] AttributeDefinition  layer=BLOCK_TB2          ext=(0.000,0.000)-(0.000,0.000) "SUBDIVISION_NAME LOT ##" at (-2.878,16.302) h=0.117
[233FB] AttributeDefinition  layer=BLOCK_TB2          ext=(0.000,0.000)-(0.000,0.000) "PREP_FOR" at (-10.088,15.740) h=0.150
[233FC] AttributeDefinition  layer=BLOCK_TB2          ext=(0.000,0.000)-(0.000,0.000) "BOUNDARY SURVEY" at (-10.186,16.219) h=0.200
[233FD] Line                 layer=BLOCK_TB2          ext=(-21.461,0.043)-(-21.461,16.434) (-21.461,0.043)->(-21.461,16.434)
[2F07C] Line                 layer=BLOCK_TB2          ext=(-0.043,13.546)-(-0.043,15.554) (-0.043,15.554)->(-0.043,13.546)
[2F07D] Line                 layer=BLOCK_TB2          ext=(-0.043,14.206)-(-0.043,16.213) (-0.043,16.213)->(-0.043,14.206)

entities=46   BLOCK EXTENTS=(-21.509,0.000)-(11.217,16.477)  size 32.726 x 16.477

Notes

What worked, what didn't, job-specific gotchas — flagged notes feed the recipes.

No notes yet.