acad-fields
Installation
SKILL.md
AutoCAD Fields (Dynamic Text)
Use this skill when creating or managing field objects - dynamic text that updates based on object properties, system variables, dates, formulas, or other data sources.
Field Class
Namespace: Autodesk.AutoCAD.DatabaseServices
Base class: DBObject
Creating a Field
// Create a field that shows the current date
Field dateField = new Field("%<\\AcVar Date \\f \"M/d/yyyy\">%");
// Create a field that shows an object property
Field propField = new Field(
string.Format("%<\\AcObjProp Object(%<\\_ObjId {0}>%).Area \\f \"%lu2%pr2\">%",
entityId.Handle));