[MS2023.00.01.44] Item Type "Is default value" not updating.

In MS2023 a new option was added in the Item Types, "Is default value".  This allows the user to change the value of a Calculated Property.  This does not update as the element the Item Type is attached to moves.

For example, If I add a property called Northing

this.GetElement().Origin.Y

and one called Easting

this.GetElement().Origin.X

then create a property called DefaultEditingTest (with the "is default value" set to true) that subtracts the Northing and easting properties. 

 this["Easting"] - this["Northing"]

When I move the element, the northing and easting update, but the DefaultEditingTest value does not update.

If I manually change the "DefaultEditingTest" value to zero, it updates:

A few questions here:

  1. Is there a config var or some other method that needs to be turned on to have this automatically update?
  2. How do I reset back to the calculated value
  3. How do I know that the value has been modified from the calculated value?  (The only way I have been able to find to do this is to set the value to zero for Integers / numbers and delete the value entirely for Text.  I haven't tried the other data types yet such as Date or Point).
  4. What if I want to overwrite the calculated value to zero?
Parents Reply Children
  • Can you try using the Subtract operator from the Expression toolbar. 

    Dash "-" and Subtract Operator "-" are different.

    DELETE5 - Copy1.dgn

  • I tried that and it did not work.  I even went as far as clearing and not typing anything in manually:

    1. In the expression builder window, I selected the "Greater than sign" in the top left
    2. Under Select Function Group I chose "This"
    3. I chose "Easting"
    4. I clicked the 'Subtract' button
    5. I chose "Northing" from the function group.

     this["Easting"] -  this["Northing"]

    Same result.

    What is the "Dash" operator and how does it differ from the "Subtract" operator?  I have been using "Dash" for a while and as far as I can tell it functions exactly the same as "Subtract".

    Is this working for you?  Are you able to send me a file using your vanilla standards with it working so I can compare to mine?

  • Hello, 

    The 'Is Default Value' was added to enable users to use get the calculated value for the first time. Once placed or during placement this field is editable and can be changed. The Item Type using the 'Is Default Value ' will not be calculated using the expression after placement .

    please check help under Home > Drawing Composition > Annotations > Item Types > Item Types Dialog

    If you want the Item to be updated, then use the 'Is Default Value' = No

    1. Is there a config var or some other method that needs to be turned on to have this automatically update?
      1. it works directly , no variable required
    2. How do I reset back to the calculated value
      1. just set the  'Is Default Value'  setting back to No
    3. How do I know that the value has been modified from the calculated value?  (The only way I have been able to find to do this is to set the value to zero for Integers / numbers and delete the value entirely for Text.  I haven't tried the other data types yet such as Date or Point).
      1. there is not way to check if its modified from the default value 
    4. What if I want to overwrite the calculated value to zero?
      1. these values are editable and can be set to any value 

    Thanks

    Nilesh Sawant



    Answer Verified By: dkleinot 

  • Thanks you for the detailed response!  I will put in a Aha! for this to be changed.

    #4 isn't accurate tho.  If I set a Number or Integer type to Zero, it will revert to the calculated value.