I am building an app where i am using grid to display the transactions which are stored in Data Service.
Requirement is to have a column in grid named as Ageing which should display the age of the transaction. Formula to be applied is (Today-Created Date). I don’t see an option in data service where i could create a calculated column using this formula. Least I tried to create a formula in UiPath Apps grid as well where I don’t see a solution to put this formula
expectation is to have value automatically either from data service / grid whenever it is loaded or a new row is getting added to data service and displayed in the grid
Appreciate your effort and thank you for your suggestion. This is a good solution provided the platform using is cloud version. For people who are using automation suite- Custom list control is not available as of now (Oct 2024)
I got a work around which I am sharing here for anyone who is looking a solution for similar scenario in Automation Suite
If we are connecting the edit gird directly with the data service - this solution won’t work. Hence create a variable of type ListSource of DataService.
Example -variable name EntGridSource. Data Service Name = GridSource
On page load - do following events
Set EntGridSource = GridSource for loading the data to Entity Variable
Use set variable again for the same variable and use the below expression
Set EntGridSource = EntSentinelApplicationQueue.data.Select(Function(item) new SentinalApplicationQueue With{.Id = item.Id,.CreateTime = item.CreateTime,.Age = CDec(CInt((Now()-item.CreateTime).Value.TotalHours))}).ToListSource
Use the EntGridSource variable as the source for edit grid instead of directly using Data Service
This way - we can use expressions for for building values in the dummy columns created for calculated fields