I have a specific use-case where I need to add 3 known values to a multi-select property. I know the values, but the folder source can only add a single value. I plan to use a workflow state to add the additional 2 values automatically and move the document to the next state however there is no simple guide to adding the additional 2 properties. I do not need to look them up, I know their IDs I just need the simplest way to add them.
I've see the sample from Bright-Ideas to lookup values that are set on related documents and lock referenced document versions to the new document etc, but there is so much extra there.
I simply need something along these lines:
Dim oProperty : set oProperty = CreateObject("MFilesAPI.PropertyValue")
oProperty.PropertyDef = 1686 'Property to add
'IDs of the property valuelist to add to the metadata card for the object.
oProperty.TypedValue.SetValueToMultiSelectLookup Array(10, 31, 41)
' Upgrade the properties for the object
Dim oNullVer : Set oNullVer = Vault.ObjectPropertyOperations.SetProperty( ObjVer, oProperty )
As a bonus, saving the values that are already entered and ADDING the additional values would be useful, but not required.