C3D-0473 · Fill SS_BLOCK_11X17 title block from job 260904 [C3D-0474] done
Update stale (job 251103 Riderwood) title-block attrs to 260904 920 W Sandtown from surveydisco: JOB, address, REF DB 16232/3170, LL 171, 19th, Cobb, Acosta Development LLC, AS-BUILT, FIRM 13067C0092H 03/04/2013, ZONE X.
C# payload
var map=new System.Collections.Generic.Dictionary<string,string>();
map["JOB_NO"] = "JOB NO.: 260904";
map["SITE_ADDRESS"] = "920 West Sandtown Rd, Marietta, GA 30064";
map["REF_DB_PG"] = "REF DB 16232 Page 3170";
map["LAND_LOT"] = "LAND LOT: 171";
map["DISTRICT"] = "DISTRICT: 19th";
map["COUNTY"] = "COUNTY: Cobb";
map["PREP_FOR"] = "Acosta Development LLC";
map["SURVEY_TYPE"] = "AS-BUILT SURVEY";
map["FIRM_PANEL"] = "13067C0092H";
map["FIRM_DATE"] = "03/04/2013";
map["FLOOD_ZONE"] = "X";
var bt=(BlockTable)Tx.GetObject(Db.BlockTableId,OpenMode.ForRead);
int changed=0;
foreach(ObjectId btrId in bt){ var space=(BlockTableRecord)Tx.GetObject(btrId,OpenMode.ForRead); foreach(ObjectId eid in space){ var br=Tx.GetObject(eid,OpenMode.ForRead) as BlockReference; if(br==null) continue; var bd=(BlockTableRecord)Tx.GetObject(br.BlockTableRecord,OpenMode.ForRead); if(bd.Name.IndexOf("SS_BLOCK_11X17",StringComparison.OrdinalIgnoreCase)<0) continue; foreach(ObjectId arId in br.AttributeCollection){ var ar=Tx.GetObject(arId,OpenMode.ForRead) as AttributeReference; if(ar==null||!map.ContainsKey(ar.Tag)) continue; var w=(AttributeReference)Tx.GetObject(arId,OpenMode.ForWrite); string old=w.TextString; w.TextString=map[ar.Tag]; changed++; Log(ar.Tag+": '"+old+"' -> '"+w.TextString+"'"); } }}
Log("changed="+changed);
Ed.Regen();
Result
Log
JOB_NO: 'JOB NO.: 251103' -> 'JOB NO.: 260904' SITE_ADDRESS: '2850 Riderwood Dr, Decatur, GA 30033, USA' -> '920 West Sandtown Rd, Marietta, GA 30064' REF_DB_PG: 'REF DB Page ' -> 'REF DB 16232 Page 3170' LAND_LOT: 'LAND LOT: 147' -> 'LAND LOT: 171' DISTRICT: 'DISTRICT: 18th' -> 'DISTRICT: 19th' COUNTY: 'COUNTY: Dekalb' -> 'COUNTY: Cobb' PREP_FOR: 'ANGELA & LLOYD BARNETT' -> 'Acosta Development LLC' SURVEY_TYPE: 'Survey' -> 'AS-BUILT SURVEY' FIRM_PANEL: '13135C0016G,' -> '13067C0092H' FIRM_DATE: 'EFFECTIVE FEBRUARY 4, 2013,' -> '03/04/2013' FLOOD_ZONE: 'AND LIES IN ZONE X' -> 'X' changed=11
Notes
What worked, what didn't, job-specific gotchas — flagged notes feed the recipes.
No notes yet.