I’m trying to construct a Text List Object in a form. I’ve been able to do it in two or three different ways but I can’t work out how to have the list display only the records which have been selected in the database (I want to use it to produce an invoice).
I thought of trying the constructlistmatrix statement because it appeared to offer more options but I can’t get it to work. The Help wizard entry has two examples:
Regarding the second question, one way to restrict records in a TextList to those that are selected is to insert info(“visible”) into the query box of the TextList options. I just discovered this in thinking about your question, so good question.
The examples on this page are just plain wrong, even the terminology is wrong, it should have said “template”, not “dictionary”. Here are the correct examples, basically just remove initializedictionary( and add quotes.
I have corrected this page, the correction is on the web version (use link below) but won’t be corrected in the in-app help until the next release.
By the way, this statement is used by the List/Matrix constructor dialog, so the documentation for that dialog also applies, and has more/better examples.
These new ones still produce errors (and, yes I did change the field names to match those of my database) but maybe that’s something to look into later.
The new examples don’t produce a compile error, but they do produce an error in the generated list object. There is a bug in the constructlistmatrix statement that causes this error in the generated formula if the template contains a non-blank line that just has spaces in it. I have fixed this bug for the next release, in the meantime, just make sure that there are no lines in the template with just spaces in them. So for now, this will work: