LinearExpansion material property bug

LinearExpansion material property bug

Anonymous
Not applicable
393 Views
1 Reply
Message 1 of 2

LinearExpansion material property bug

Anonymous
Not applicable

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.

0 Likes
394 Views
1 Reply
Reply (1)
Message 2 of 2

xiaodong_liang
Autodesk Support
Autodesk Support
Hi,

i have not 2013 at this moment. I tested with 2014. After the line oNewMaterial.LinearExpansion, I checked the property in watch window. It looks it is correct.
Without this line, the default value for the new material is 10 -6.
could you clarify your question with some snapshots?
0 Likes