App Screen Not Updating

I Have a strange example of where I have added some fields to a block and they are not being shown on the app. The field visibility is set to true, here is a screen shot and we can see that the Line Header ID label is showing, but the fields to the right are all one line higher than they should be and the ID data field is not showing.

UPDATE: I have found that this is happening because the variable is not getting the value it is being passed, so here is the full process:

We start with a list of sales leads, taken directly from a table:

It sends THISROW() to the next screen, sales leads detail $[InputRow], where that screen finds the row in the sales leads header table

We then have a button that launches the sales leads new action screen, sending it the inputrow, which in the builder evaluates to 4

Sales leads new action has a field to accept the input

When we run through the process this is what happens, firstly from the sales leads list screen, we select the first record

This jumps us to the sales leads details screen, shows the passed field value as 4, finds the source record and displays it.

Next we click the Go >> button and we see that it works just fine, if there is a record with that ID already in the SalesLeadsLines table

However, if I choose a record on the header, where there is not yet a matching record in the sales leads lines table, then the Line Header ID is simply not populated.

Note that the block containing that field is not linked to anything.

My understanding of how this should work, is that I am picking up a value from a screen field and sending it to a newly opened screen and populating a variable field on that screen with the value. The destination screen should just open and display the value in the receiving field.

I tried different ways of sending the value - I hard coded it to text or numeric values and tried specifying a field from the source table

image image

But under any circumstance, when a record with that value doesnt exist in the Sales Leads Lines table, the value does not appear in the field it is passed to, even though that block is not trying to do any lookups based on it.

So confused!

I'm not sure this will fix your issue, but it might. On the GO >> button on the Sales Leads Detail screen, where you have take data from =$[InputRow] and write to =$[INPUTLinesHeaderID], try changing =$[InputRow] to =$[InputRow][LineHeaderID].

Hi Isaiah, thanks for the feedback, it makes a lot of sense that I should be able to take the header ID (note the InputRow of the sales leads detail form - the calling form - is getting its data from Sales Leads Header) and pass it to the called form. Indeed adding the field to the end of InputRow does evaluate to the current record ID.

However, after calling the next form and passing it, the INPUTLineHeaderID is not populated, unfortunately.

Ok I have found out why this is happening and would be very happy if someone could clarify if this is a bug or a lack of understanding on my part.

It seems to be all to do with where the button is placed, if it is in the block that performs the FindRow then it is able to send the variable to the next screen, even if there is no record in the next screen's underlying table that matches. However if the button is somewhere else on screen, when there is a record in the next screen's underlying table, it is able to send the variable, but if there is no record either the next screen simply doesnt accept the variable or the button loses context to the InputRow. This diagram should explain it.

That does seem to be a bug as best as I can tell from your description. I'd like to create a demonstration of the issue myself. Are you able to describe how to recreate the bug from scratch?

I'm curious if setting the source of Block3 of Sales Leads Detail to =$[InputRow] changes anything.

Hi @PaulBappoo,

Thanks for the detailed set of images from your application. First, you may benefit from reviewing the following post about passing parameters between screens:

I am not sure I completely follow what you are doing, but here are few suggestions and items for you to check:

  1. In the Sales Leads Detail screen, you specify the $[InputRow], and then you set its initial value to FindRow(SalesLeadsHeader). This is needed ONLY if you will land on the Sales Leads Detail screen without passing a value to it from the Sales Leads List. In the case when you land on the Sales Leads Detail screen from outside of navigating from Sales Leads List, you will get the first row from the Sales Leads Header. Typically, detail screens are never navigated to do directly - only by clicking on a row within a list - so you do not need this Initial Value.

Similarly, you also have the Initial Value defined for $[INPUTLineHeaderID] to $[PASSEDLineHeaderID]. It is not clear what this value is, and why the initial value is set to this.

  1. In your most recent message, you specify Block3's Data to be FindLastRow(...). So in this case, your block is trying to lookup the last row from the SalesLeadsLines - and if there is no such record, then in effect the mapping of fields in the block would be blank. This is the reason you are seeing blank data.

  2. In order to debug, you can create a block at the top of the screen and display all incoming variables from the previous screen. You can see the blue section in the link I pasted earlier as an example. One pattern is to do this on every screen, and set its visibility condition to FALSE - so the block remains there and you can turn it back on if needed later on.

  3. If there are no SalesLeadsLines, should the Go button be hidden? You can use ROWS(Filter(...)) > 0 to display the button if want to hide the button. Or alternatively, you can do the same to hide the block if needed.

Hope this helps.


1 Like

This is all very useful, thanks a lot for your help. I am going to sit down and try to re-create this from scratch and see how it goes

1 Like

Hi @PaulBappoo, how'd it go, and how's your app building journey going? Looks like you have some pretty impressive forms/apps happening!