I need to get work flow Item by serial number without opening Item.
When I used below code does not return any thing:
Work Field doesn't contain field called serialnumber
I use this code instead:
When I used below code does not return any thing:
WorklistCriteria criteria = new WorklistCriteria(); criteria.AddFilterField(WCField.SerialNumber, WCCompare.Equal, serialNumber); SourceCode.Workflow.Management.WorklistItems wl = cnnWMS.GetWorklistItems(criteria); |
Work Field doesn't contain field called serialnumber
I use this code instead:
WorklistCriteriaFilter criteria = new WorklistCriteriaFilter(); RegularFilter rfPID = new RegularFilter(); RegularFilter rfActID = new RegularFilter(); // why doesn't setting this prevent me from knowing alias? Are there constants or enums to use? //rfPID.TableName = "K2Server.dbo._ProcInst"; rfPID.ColumnName = "PI.ID"; rfPID.ParameterValue = serialNumber.Substring(0, serialNumber.IndexOf('_')); rfPID.DbType = DbType.Int32; rfPID.Comparison = Comparison.Equals; rfPID.ParameterName = "@ICE_ProcInstID"; criteria.FilterCollection.Add(rfPID); rfActID.Condition = RegularFilter.FilterCondition.AND; // why doesn't setting this prevent me from knowing alias? Are there constants or enums to use? //rfActID.TableName = "K2Server.dbo._WorklistHeader"; rfActID.ColumnName = "WLH.ActInstDestID"; rfActID.ParameterValue = serialNumber.Substring(serialNumber.IndexOf('_') + 1); rfActID.Comparison = Comparison.Equals; rfActID.ParameterName = "@ICE_ActInstID"; rfActID.DbType = DbType.Int32; criteria.FilterCollection.Add(rfActID); SourceCode.Workflow.Management.WorklistItems wl = cnnWMS.GetWorklistItems(criteria); |
No comments:
Post a Comment