Hi All
I need an ilogic rule for tube and pipe length
for example:
for each pipe when the length (QTY column ) is between 0-4.99 m another column (Item QTY for example) the value will be : 5m . when the length between 5-9.99 m the value will be 10m , when the length between 10-14.99 m the value will be 15m . If the length will be at inch can it convert to m , and than change the other column value ?
Regards
Solved! Go to Solution.
Solved by nstevelmans. Go to Solution.
Solved by nstevelmans. Go to Solution.
Dim oDrawDoc As DrawingDocument = ThisApplication.ActiveDocument
Dim oUm As UnitsOfMeasure = oDrawDoc.UnitsOfMeasure
Dim oSPL As Double = 5000 'oSingle section pipe length(‘mm’)
Dim oILP As Double = 5'Installation loss percentage(0~100)
For Each oSheet As Sheet In oDrawDoc.Sheets
For Each oPartslist As PartsList In oSheet.PartsLists
For Each row As PartsListRow In oPartslist.PartsListRows
Row.Item("QTY").Static = False
Dim oValue As Double
Try
oValue = CDbl(Row.Item("QTY").Value)
Catch
oValue = oUm.GetValueFromExpression(Row.Item("QTY").Value, UnitsTypeEnum.kInchLengthUnits)
oValue=Math.Ceiling(oValue*(10+oILP/10)/oSPL)
End Try
Row.Item("QTY").Value = CStr(oValue)
Next
Next
Next
Just try this.
Can't find what you're looking for? Ask the community or share your knowledge.