I am using the AF SDK to read Attribute data back from a Case and although I have the right case when I reference the elements it is going to the information in the Elements list for the Model rather than the copy of the Elements in my Case.
I had assumed that when I code something similar to the fragment below the indexing of "afCase.Elements" (line 3) would return the element information from within the Case.
1 for (idx = 0; idx < elementLst.Length; idx++)
3 if ((afElement = afCase.Elements[elementLst[idx]) == null)
5 Console.WriteLine(func + ": Warning Msg : Element '" + elementLst[idx] + "' is not defined in Model");
6 retState = RCDE.WARN;
10 AFAttribute afAttribute = afElement.Attributes["MeasuredMass"];
11 values[idx] = (double) afAttribute.GetValue().Value;
Is there an explantion anywhere of why this behaviour is occuring?
Which Element list should I be indexing to get the values from the case attibutes?