Hi guys,
I use a macro to add a new material in a .ipt, but the value of LinearExpansion property is ever set to 500. If I remove the line in the macro, the value of LinearExpansion property is 0,1.
I use Inventor 2013 SP2 update 2.
The code is this (taken from API help):
Public Sub CreateMaterial()
' Set a reference to the part document.
' This assumes a part document is active.
Dim oPartDoc As PartDocument
Set oPartDoc = ThisApplication.ActiveDocument
' Create a new material.
Dim oNewMaterial As Material
Set oNewMaterial = oPartDoc.Materials.Add("18NiCrMo5", 7.86)
' Define the other properties of the material
oNewMaterial.LinearExpansion = 12
oNewMaterial.PoissonsRatio = 0.3
' Arbitrarily assigns the first render style in the render styles collection.
' oNewMaterial.RenderStyle = oPartDoc.RenderStyles.Item(1)
oNewMaterial.SpecificHeat = 0.49
oNewMaterial.ThermalConductivity = 47
oNewMaterial.UltimateTensileStrength = 800
oNewMaterial.YieldStrength = 600
oNewMaterial.YoungsModulus = 206
End Sub
Is It a bug?
Thanks in advance. Have a nice day.
Angelo.