Hi every one,
i'm totaly new with M-Files and I'd like to know if there is a way to automaticaly recalculate the property of an object every day.
Thanks
Hi every one,
i'm totaly new with M-Files and I'd like to know if there is a way to automaticaly recalculate the property of an object every day.
Thanks
Option Explicit
dim iWFState : iWFState = vault.WorkflowOperations.GetWorkflowStateIDByAlias("")
Dim oPropVal: Set oPropVal = CreateObject("MFilesAPI.PropertyValue")
oPropVal.PropertyDef = 39 ' Workflow states build-in property
oPropVal.TypedValue.SetValue MFDatatypeLookup, iWFState
Vault.ObjectPropertyOperations.SetProperty ObjVer, oPropVal
That should be possible. You would have to get the version number of the previous version, get the propertyvalues from that version and then get the value of the workflow state. I do not have a script on hand for that nor do I have the time to create one at the moment.