cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Akatamaoka
Level: Powered On

Collection of DataTables

Each screen in my application is a DataTable displaying a different view from a database.

I was hoping to set this up so when a user clicks a row in any of the DataTables, they are taken to a common "View" screen, which populates a Display form with

Item: varDataTable.Selected

Depending on which screen they came from, the source DataTable will be different, so I wanted to pass the clicked DataTable to the View screen in a context variable (so I don't have to have a separate View screen for each DataTable).

Navigate(View,ScreenTransition.None,{varDataTable: datListAll})

This works for one screen, but as soon as I add it to another screen, I get an error that says:

Incompatible type. We can't evaluate your formula because the context variable types are incompatible with the types of values in other places in your app.

Is there a better way to do this?

 

01.pngList All screen - passing the DataTable in a context variable works02.pngManagement screen - context variable does not work03.pngView screen - it doesn't like populating the Item from a variable, I guess

1 REPLY 1
Super User
Super User

Re: Collection of DataTables

Set the item property of the of the form to Lookup(datasource,ID=varDataTable.Selected.ID). The datasource of the form must be the same as the datasource of the lookup.