on 07-22-2014 5:47 PM
Hi;
I am working on SAP Work Manager 6.0 customising using Agentry 6.1.3. I have an object InspectionOrder, that has a collection of InspectionPoints, which in turn has a collection of InspectionTasks. I am working on having the images of these objects updated on tile lists on the device. I am using the windows .NET client for testing. Currently I have managed to have the InspectionTasks image to change to completed once the required fields have been filled in, I am using rules here. I have archieved this as follows:
How can I possibly count the number of InspectionTasks with "Completed" image and compare this with the number of InspectionTasks in the collection, if the two are equal then this implies that all InspectionTasks within an InspectionPoint have been completed, and hence the InspectionPoint image must change to completed as well.
Thanks in advance.
Sizo Ndlovu
Sizo,
You can use the COUNT function against a collection. You can also use selection criteria as a second parameter to COUNT to check the completed status:
IF
EQNUM
COUNT
InspectionPoint Object -> InspectionTasks Collection
COUNT
InspectionPoint Object -> InspectionTasks Collection
EQSTR
InspectionTask Object -> Status property
COMPLETED
ImageComplete
ImageIncomplete
The above will compare the count of all tasks against the count of completed tasks and return the correct image name.
Jason Latko - Senior Product Developer at SAP
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
9 | |
7 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.