PdcMaterial.CostKind

From External Bemet Wiki
Jump to navigation Jump to search

Declaration

CostKind as String

Description

Returns or changes the costkind

Notes

This property sets or returns the cost kind of a material, when used in a user interface, please have this populated from the cost kind table (28) using pdc.ChooseRecord.

Code example

This code example opens a calculation, loops through its materials and sets the cost kind to a chosed value.

dim objCalc

  set objCalc = pdc.OpenCalculation("00685")
  for i = 0 to objCalc.MaterialList.Count -1
    set objMat = objCalc.MaterialList(i)
    objMat.CostKind = pdc.ChooseRecord(28,"","")
  next

Availability