Matrix not filling properly from lookup(


Here’s a shot of a form with a matrix object:

The form is constructed just to illustrate this bug: the Get Started button has this procedure:

showvariables fgTest````

The formula for the matrix is `commatocr(fgTest)`

The Matrix Frame has 3 objects. The top one is a TDO with the formula `info("matrixcelldata")`
As you can see, it works in each frame of the matrix.
The other 2 objects in the frame are lookups, displaying a photo and a text snippet respectively. The formulas for those are: `lookup("FlowerEssences",Name,info("matrixcelldata"),Photo,"")` for the image display object and a corresponding one for a TDO.

As can be seen from the screenshot, these formulas work in the Matrix Frame and, in the matrix itself, for the corresponding record; but not for the other two records. 

Am I doing something wrong, or is this a bug in the lookup( function, or? 

I worked on this months ago and then dropped it. I hoped that the latest version of PX, which had some fixes to matrices, might have resolved my problem, but it doesn't. I thought I had asked about this problem before and even sent Jim copies of the files, but I can't find any of that correspondence here, in BitBucket, or in my own email records. Maybe I didn't, or maybe I just lost the evidence....


I don’t recall that and can’t find it here either.

The obvious question is, are you sure that your FlowerEssences database contains entries for AcrobatOrchid and BlueLechenaultia? Maybe the database records have spaces in them?

What happens if you run the lookup( formula from the Formula Wizard with these data values? There is no reason why lookup( should work any differently in a matrix than it does anywhere else.


Duh. The photo names don’t have a space, but the names do. Blush.

Jim Rea wrote: