Often ProdID is used to do conditinal tasks such as picking only certain objects on the line. You can set different materials for different ProdID at the creation phase. Check the attached example on how ProdID can be used for conditional picking.
You can read other component properties with syntax #PropertyName. So for example you can create a task “Print:Material is #Material:True:True” which looks for property named “Material” and prints it on the console. Only problem is that Material property is of type vcMaterial and not string so the output will print “Material is <vcMaterial object at 0x00000249B4591150>”. So you would need to be able to read Material.Name which is a property within a property. That is not supported on Works by default so you would need to customize the works tasks on python.
You could write a python script attached to a sensor on the conveyor, that checks the ID/Material of the current part. If the ID is the desired one you can call a pick-function.
For example:
while app.Simulation.IsRunning:
triggerCondition(lambda: sensor_signal.Value != None)
part = sensor_signal.Value
ID = part.getProperty("ProdID")
if ID = "2":
robot.pick(part)