Is it possible to set a field to ReadOnly?
I create a definition field, I can with a bit of trickery, set the import/export definition to ReadOnly.
So for example, if I have a TERM_UUID field, how can I make the field itself ReadOnly, so that the value cannot be changed by the end user?
I am using the SDK to view the TermFields:
Entries oEntries = oTb.Entries;
Entry oEntry = oEntries.Item(1);
EntryIndexes oIndexes = oEntry.Content.EntryIndexes;
EntryIndex oIndex = oIndexes[0];
Console.WriteLine(oIndex.Term);
Console.WriteLine("Number of term-level descriptive fields: " + oIndex.TermFields.Count.ToString());
for (int i = 0; i < oIndex.TermFields.Count; i++)
{
Console.WriteLine(oIndex.TermFields["i"].Name + " " + oIndex.TermFields["i"].ReadOnly);
}
This results in:
asdasd
Number of term-level descriptive fields: 1
TERM_UUID False
But I cannot set: TermField["i"].ReadOnly = True
Logically, if the TermField has a ReadOnly property == "False", then surely one should be able to change it to "True", either programmatically or set it to "True" by default?
Kind regards
Samuel