Just showing the newer way to do this, since the code shown in both of those posts is using objects and properties that have been outdated / obsolete since 2013, and I am not sure how much longer they will be supported. You can review the following online help link for more details about that.
Consistent Materials (Materials and Appearances)
The newer objects and properties do seem to be a little more complicated to use, so I do not blame anyone for wanting to keep using the older methods for as long as they continue to work. Since the newer Asset object (and the derived MaterialAsset) is now used for representing materials, appearances, and the physical properties of materials, they do not have a lot of public, logically named properties for each of the individual pieces of information that they can possibly store (there are a ton of them), all detailed information is now stored within AssetValue type objects, within the Asset. And the AssetValue type is just a base type for 9 other derived, and more specific sub types, for the different types of values they can have. Some can even have multiple values. Each one has a 'Name' and a 'DisplayName', with the 'Name' being the language stable way to go, but has a less obvious value.
The example below is using the 'Name' property, so that it will be language stable.
Dim oDoc As PartDocument = ThisDoc.Document
Dim Mat As MaterialAsset = oDoc.ActiveMaterial
Dim Phys As Asset = Mat.PhysicalPropertiesAsset
Dim MatName As String = Mat.Name
Dim FloatAV_ForPoissonsRatio As FloatAssetValue = Phys.Item("structural_Poisson_ratio")
Dim PR As Double = FloatAV_ForPoissonsRatio.Value
Dim FloatAV_ForDensity As FloatAssetValue = Phys.Item("structural_Density")
Dim Den As Double = FloatAV_ForDensity.Value
Dim FloatAV_ForYieldStrength As FloatAssetValue = Phys.Item("structural_Minimum_yield_stress")
Dim YS As Double = FloatAV_ForYieldStrength.Value
Dim FloatAV_ForTensileStrength As FloatAssetValue = Phys.Item("structural_Minimum_tensile_strength")
Dim TS As Double = FloatAV_ForTensileStrength.Value
MsgBox("材质 " & MatName & " 的泊松比: " & PR &"/ 密度: " & Den &"/ 屈服强度: " & YS & “/ 抗拉强度:” & TS)
Wesley Crihfield

(Not an Autodesk Employee)