Set up the first 25 row portal the way you want it. While in layout mode either ctrl-drag (option drag on mac) or copy paste to make an exact copy of the portal. Double click it to open portal set up and change the Initial row setting to 26.
This way i can only create records in the Appointment-table when i am in the first portal.
There"s no problem creating the first 25 appointments, when i want to create the 26nd record i am only able to do this in the first portal, although it appears in the second portal afterwards.
Is this normal? Can i change this?
That should not be the case.
If you have enabled "allow creation of records via this relaitonship", this will cause an "add row" to appear in your portal as a blank row for adding records. This will appear after the last row in your portal that represents an actual related record. Once you have created 25 records in the first portal, the add row should appear as the first row in the second portal.
See the example screen shot. The bottom portal is a four row portal. The upper portals are to the same table occurrence, but the first shows rows 1 and 2 while the 2nd shows rows 3 and 4. Note how with two records in the portal, the add row shows as the top row of the second portal.
But when dealing with a large number of records in a portal, it often becomes simpler to use a button near your portal that performs a script for adding new portal records.
Should i use a gobal date field to create a record with a button?
It's an option, but all you really need is a new blank record in your portal in which to enter the data.
A commonly used option is to sort the records so that the oldest appointments are at the bottom of the portal and the newest are at the top. Then a new portal record can be created that automatically appears as the new top portal row when you click the button.
It can be as simple as this script:
Set Variable [$ID ; value: Person::__pkPersonID ]
Go to layout ["appointments" (appointment) ]
Set Field [appointment::_fkPersonID ; $ID ]
Go to Layout [original layout]
But you can add a global date field to your layout or inside a custom dialog and then an additional set field step can assign that date to the new appointment record if you want.