C3D-BND702 · 358 St Johns - boundary (60.07x170) done
Deed-call rectangle 60.07x170 (10,212 sf) anchored at IPF #137, on C-PROP-LINE. Move to fit.
C# payload
// Boundary for 358 St Johns Ave: 60.07 x 170 rectangle from deed calls, anchored at IPF pt #137.
// N36-44-12E 60.07 / N53-15-48W 170.00 / S36-44-12W 60.07 / S53-15-48E 170.00 (closes to 10,212 sf)
var bt = (BlockTable)Tx.GetObject(Db.BlockTableId, OpenMode.ForRead);
var ms = (BlockTableRecord)Tx.GetObject(bt[BlockTableRecord.ModelSpace], OpenMode.ForWrite);
EnsureLayer("C-PROP-LINE");
double d2r = System.Math.PI / 180.0;
var pts = new List<Point2d>();
var cur = new Point2d(2225443.14, 1346018.10); // IPF #137 (X=Easting, Y=Northing)
pts.Add(cur);
(char ns, double deg, double min, double sec, char ew, double dist)[] calls = {
('N',36,44,12,'E',60.07), ('N',53,15,48,'W',170.00), ('S',36,44,12,'W',60.07), ('S',53,15,48,'E',170.00)
};
foreach (var c in calls) {
double a = (c.deg + c.min/60 + c.sec/3600) * d2r;
double dy = c.dist * System.Math.Cos(a) * (c.ns == 'N' ? 1 : -1);
double dx = c.dist * System.Math.Sin(a) * (c.ew == 'E' ? 1 : -1);
cur = new Point2d(cur.X + dx, cur.Y + dy); pts.Add(cur);
}
var pl = new Polyline();
for (int i = 0; i < 4; i++) pl.AddVertexAt(i, pts[i], 0, 0, 0);
pl.Closed = true; pl.Layer = "C-PROP-LINE";
ms.AppendEntity(pl); Tx.AddNewlyCreatedDBObject(pl, true);
Log($"Boundary h={pl.Handle} area={pl.Area:F0} sf ({pl.Area/43560:F3} ac) closure={pts[0].GetDistanceTo(pts[4]):F3}' (plat: 10,212 sf / 0.234 ac)");
Result
Log
Boundary h=209FB area=10212 sf (0.234 ac) closure=0.000' (plat: 10,212 sf / 0.234 ac)
Notes
What worked, what didn't, job-specific gotchas — flagged notes feed the recipes.
No notes yet.