Skip to main content

Notifications

Announcements

No record found.

Business Central forum

Page with SourceTableTemporary and Repeater

(0) ShareShare
ReportReport
Posted on by 15

Hello,

I am creating a Business Central extension that has a page with a repeater. The page has a source table and SourceTableTemporary is set to true. The logic on the page inserts new items in the temporary table and the repeater is supposed to list them.

One of the problems is that once I insert one record, all subsequent inserts will throw an exception for a duplicate primary key. My key is an integer so I fixed this by adding an increment to the primary key (note that the primary key on the table is defined with AutoIncrement).

"No." := Count() + 1;
Now that I can insert multiple fields in the table it turned out that the repeater only shows the last inserted record instead of listing all records.
So, my question is - how can I create a NavigationPage, which lists multiple temporary records?
Thanks!
UPDATE 1: I accidentally did the following:
  1. Insert an item in the temp table and it shows on the first line in the repeater.
  2. Select the second line of the repeater, which is blank.
  3. Insert a second item in the temp table and it shows in the second line of the repeater.
  4. Insert a third item while the second line is selected and the second item in the repeater get replaced by the third item.

How can I move the selected repeater line to the next blank line after a record is inserted? My goal is to allow a user to enter data press enter and add items to a list.

Categories:

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

November Spotlight Star - Khushbu Rajvi

Congratulations to a top community star!

Forum Structure Changes Coming on 11/8!

In our never-ending quest to help the Dynamics 365 Community members get answers faster …

Dynamics 365 Community Platform update – Oct 28

Welcome to the next edition of the Community Platform Update. This is a status …

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,642 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,371 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans