Announcements
I made a query which I would like to display on a page. The query works fine and returns a dataset. But I can't seem to be able to display it on a page. My steps where:
OnOpenPage()
myQuery.OPEN;
WHILE myQuery.READ
DO BEGIN
NextRowNo := NextRowNo +1;
Entry := NextRowNo
END;
myQuery.CLOSE;
But nothing shows up on the page. It only shows 'Entry' column, not the others. Also, there's no data.
Is the correct way to do so? Do I need to assign every field from the query as a global value?
That helped, but it seems I need to create each column in the table assign every value in the C/AL code. If I show it as in the screenshot (so myQuery.Entry_No on the page) I'm getting an error saying that the column needs to be read first. And if I assign it as a global value, I'll get a column without a name which isn't sortable.
So in the end, it looks like I can't use reference like myQuery.Entry_No directly on the page. Is that how it supposed to work?
Hello,
Try to add the following:
Page Property SourceTableTemporary = Yes
Then add INSERT; in your loop.
That should insert the data, but of course only locally (client-side) for the use of the page.
André Arnaud de Cal... 291,359 Super User 2024 Season 2
Martin Dráb 230,370 Most Valuable Professional
nmaenpaa 101,156