Showing results for 
Search instead for 
Did you mean: 

Allow Collections to be used as a DataSource in Forms

Collections can be used as the data source in a display or edit form. However, you cannot then add fields based on the collection you have entered. The "edit fields" tab only allows you to tediously make individual custom datacards.


Can we get support for collections to be used in forms like they are in galleries and data tables?

Status: New

Make a DataSource a type of collection. In other words, enable mirroring of a collection with what is now a DataSource, and make all the syncing automatic. Give it a boolean property "Online". It can be hard set to true to behave how a DataSource does now, but will read false when connection is lost. It can be hard set to false to only sync when Refresh is called. Setting it to a variable, or a more complex expression, will allow the program to change modes programmatically.

Kudo Kingpin

@sopatte I'm not sure how that is relevant to this idea. 

Not applicable

I am using a collection with an edit form (manually created and binded the data fields) and interestingly it seems to work for some of my data fields and not others. 


Having the ability to bind a collection to a form would be very useful. My use case is an app with offline functionality so when connected, it points directly to the data source and when offline it points to the collection. 

I found the reason it was working with some columns but not others is because of a separate bug with the Patch() function on local collections with NULL fields where it can not update the field. 

It appears the forms emulate this behavior when they submit data. 

Kudo Kingpin

This issue can be worked around relatively easily if you are using a collection which is just a replica of a CDS entity, since you can just build the form based on the entity and then swap the datasource to the collection.
But there is not a good workaround to quickly creating a form if you have manually created a collection which you want to edit.


@Boneckrh19 This method doesn't seem to be working anymore as the fields not connected to the CDS entity do not show up on execution.