I need to use below function in my MS Project vba macro.
Application.CustomFieldValueListAdd FieldID:=lookupfield, Value:=i
It works fine for local field(field created locally in ms project in active project). But it doesn't work for Enterprise Custom Field of Task type. I am able to get id using function FieldNameToFieldConstant("Product_task", pjTask), but it is giving error if I use this generated id in first function. I hope my problem is clear.