Hi,
I'm trying to Patch a collection OnChange of a dropdown, but I am getting the invalid argument error.
My collection has a field called "IsSelected" which is set to true when the item is selected in the gallery. This allows me to have multiple items selected at the same time. These are the lines of the collection which I need to update.
My formula is:
Patch(
colTables
,Filter(
colTables
,LineSelected=true)
,{IsDirty: true
, ID_Technologies: DdTechnologyDetails_Tables.Selected.Id_Technologies}
);
Can anyone enlighten me on where the problem is?
Thanks in advance!
Solved! Go to Solution.
Patch only works with datasources and new records in collections. You can't use it with Tables or to update existing records in collections. I think what you are looking for is updateIf. Is colTables a table, a collection, or a datasource?
Patch only works with datasources and new records in collections. You can't use it with Tables or to update existing records in collections. I think what you are looking for is updateIf. Is colTables a table, a collection, or a datasource?
Hi,
Thanks for your speedy and very helpful reply, that seems to have sorted it!
UpdateIf(
colTables,
LineSelected=true
,{IsDirty: true, ID_Technology:DdTechnologyDetails_Tables.Selected.Id_Technologies}
)
User | Count |
---|---|
142 | |
142 | |
76 | |
73 | |
71 |
User | Count |
---|---|
231 | |
170 | |
74 | |
69 | |
60 |