Do we have a simple scripting way to change all/some legend values of my stress plot in Mechanical?
#Automated Script #10 Values for a standard Legend with 9 Bands #Blank can be input as None #Order is lowest to Highest. legendVals = [None,None,1.2,None,None,None,None,None,2.8,None] def changeLegend(data): legendSettings = Ansys.Mechanical.Graphics.Tools.CurrentLegendSettings() i = 1 for val in legendVals: if val != None: if i < len(legendVals): legendSettings.SetLowerBound(i-1, Quantity(val,"MPa")) else: legendSettings.SetUpperBound(i-2, Quantity(val,"MPa")) i += 1 changeLegend(legendVals)