Hey, I found this feature request that does not seem to have much support. That means people have some workaround how to save certain properties by reference (value or both as mention in the feature request). Can anyone please share it? I have no Idea how to implement it properly. Thank you
This it the request:
https://moodkie.com/forum/viewtopic.php?f=14&t=1995
Attribute for reference
Re: Attribute for reference
Hi there,
To do this you would create an ES3Type (see https://docs.moodkie.com/easy-save-3/es ... g-es3types), and then modify the writer.WriteProperty calls in ES3Type to include the memberReferenceMode parameter.
I.e. instead of this:
Use this:
However, we've seen very few situations where people have needed to do this over the past 10 or so years we've been doing this, which is why it's not explicitly documented and hasn't been implemented as attributes.
All the best,
Joel
To do this you would create an ES3Type (see https://docs.moodkie.com/easy-save-3/es ... g-es3types), and then modify the writer.WriteProperty calls in ES3Type to include the memberReferenceMode parameter.
I.e. instead of this:
Code: Select all
writer.WritePropertyByRef("dict", instance.dict);
Code: Select all
writer.WriteProperty("dict", instance.dict, ES3.ReferenceMode.ByRefAndValue);
All the best,
Joel