← Inbox

C3DO-0888 · 251205: new points 579-581 - clear own style/label to match existing points [C3D-PTSTY1205] done

Sets point style and label style on 579/580/581 to whatever existing point 575 carries (null), so they display only through point groups like every other point.

Script file
C3DO-0888.cs
Target
251205 - 157 Scenic Hwy N.dwg · model space
Author
claude
Approved
yes · auto-auth
Timeout
60s

C# payload

var civ=CivilDoc;
string N(ObjectId id){ if(id.IsNull) return "null"; try{ return ((Autodesk.Civil.DatabaseServices.Styles.StyleBase)Tx.GetObject(id,OpenMode.ForRead)).Name; }catch{ return "?"; } }
var ref1=(Autodesk.Civil.DatabaseServices.CogoPoint)Tx.GetObject(civ.CogoPoints.GetPointByPointNumber(575),OpenMode.ForRead);
Log("575 (existing) style="+N(ref1.StyleId)+" label="+N(ref1.LabelStyleId));
foreach(uint n in new uint[]{579,580,581}){ var cp=(Autodesk.Civil.DatabaseServices.CogoPoint)Tx.GetObject(civ.CogoPoints.GetPointByPointNumber(n),OpenMode.ForWrite);
 string b="style="+N(cp.StyleId)+" label="+N(cp.LabelStyleId);
 try{ cp.StyleId=ref1.StyleId; cp.LabelStyleId=ref1.LabelStyleId; }catch(System.Exception ex){ Log(n+" set failed: "+ex.Message); }
 Log(n+": "+b+" -> style="+N(cp.StyleId)+" label="+N(cp.LabelStyleId)); }
Ed.Regen();

Result

Status
success
Drawing file
C:\Users\sanja\OneDrive\_SurveyDisco\251205 - 157 Scenic Hwy N, Lawrenceville, GA 30046, USA\251205 - 157 Scenic Hwy N.dwg
Message
Executed C3DO-0888 (0 entities touched).
Entities
—
Duration
952 ms
Civil 3D
25.0.0.0

Log

575 (existing) style=null label=null
579: style=Basic label=Point#-Elevation-Description -> style=null label=null
580: style=Basic label=Point#-Elevation-Description -> style=null label=null
581: style=Basic label=Point#-Elevation-Description -> style=null label=null

Notes

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

No notes yet.