How to Read Measures from Part with NXOpen

I have a part with several measures (Analysis->Measure). I have renamed them to something descriptive (e.g., CylinderHeight).

Now what I would like to do in the journal is get the value for a specified measure, for instance:

myDouble = GetMeausureValue(measureName as String, measureType as ?)

something like that .....

I tried to reverse engineer a recorded journal but haven't made much progress, any hints or ideas? If I knew how to find the object with the correct measureName that would really help.

Thanks

Is this an associative measure feature that you have created? If so, you should be able to find the feature by name then read the expressions created by the feature to find the length.

What version of NX are you using?

Yes it's associative, I'm using NX1872.

I did just notice (after posting) that I can find the associative measures in the Expression GUI list. So I think I might be on to something there, since I know how to edit expression values, and the NXOpen.Expression object is understandable in the debugger window. I'll post back if I figure it out. Thanks!

it was very easy:

Public Sub PopulateValue()
For Each temp As Expression In workPart.Expressions
If temp.Name = Param Then
Value = CStr(temp.Value)
End If
Next
End Sub

where "Param" is the name of the expression I'm looking for, and "temp.Name" is the name of an expression in the current workpart expression list (i.e., workPart.Expression). Measures and parameters are stored in the GUI at Tools->Expressions, so you just have to rename them to something more descriptive and that matches whatever string you assigned to "Param"