Civil 3d Mtext Set Parameter Locking program

I am attempting to create an Mtext then change the parameter of Annotative from False to True
See Picture below.

The Issue I am having it is either not working or locking up so I have to reset Civil3d.
I’ve used Boolean, String, Codeblock nothing seems to work. Is my workflow messed up?

I should mention that locking program means it will no longer create the mtext even if I unconnect or delete the setparameter.
Error is usually gives me is invalid openstate

Hi Harry, welcome :wave:
The DBObject.Annotative (For MText, Text, etc.) property is set with the AnnotativeStates Enum which will evaluate as an integer, so True=0, False=1, NotApplicable=2
Try setting the property with 0
See DBObject.Annotative and AnnotativeStates

I am sad to report that it did not work. While it didn’t give me an error it also didn’t change.
I seem to be able to change anything that requires an integer like height, rotation without issue. I try anything with a boolean like background color. It doesn’t work.

Best to post a simple DWG (one element with a property to set) and your DYN that is failing? Also note what Civil 3D version you’re using.

I am using Civil3d 2024.
Yes, the DYN is failing but only the setparameter. Everything else works. It either doesn’t work in case of putting in the number or failed openstate if I try boolean, string, or codeblock.
I cannot upload because I am a new user it says

Just bumped your trust level - upload away!

If it doesn’t work, give it ~10 minutes to push cache updates (the joy of the internet), and if that still fails let me know and try another service like Google Drive, Dropbox, Box, Onedrive, etc. with ‘open to anyone with the link’ permissions.

Dynamo Distance.dyn (47.5 KB)

Drawing2blank.dwg (452.3 KB)

Thank you.

Your Code Block does not contain a boolean object. Try typing ‘true’ instead of ‘True’.

Thank you,
I’ve tried boolean - gives me invalid open state error.
I just tried true instead of True. Still same error.

Seems it’s a bug with Civil 3D toolkit. That package is no longer supported (hasn’t been a for awhile) , so updating to a newer release is the easiest next step. The other option is to look into building your own custom script or code to tackle the issue.

HI @HarryDresden if you have the chance to update to 2026 its as easy as this.

Does newer Dynamo’s work with older civil 3d. My gut says no but always hoping.

It isn’t a bug, that property is just not writeable. What Mike says, it needs an Enum.

In my package, The Civil Nodes, the Get and Set Parameters nodes work the same as C3DToolkit.

The Property Annotative returns a loolalike boolean (mind the capital F), which probably is a visual representation of the underlying Enum.

Trying to set this parameter with a boolean, or a 0 like Mike suggested, does not work:

So the only solution is a node that is made for this:

But that node is not available in Civil 3D 2024.

I think that settles it.
Thank you appreciate it.