What you want to do is possible, but a little arcane. Essentially, you'll need to set up a few things to make this work:
1) A global field matching the type of the key field of your patient (number, text, whatever).
2) A relationship between that global field and the key field of the record you're currently browsing.
3) A method for assembling the record IDs of the found set into a return delimited list and inserting that list into the global field.
You'll base your portal on that relationship:
GlobalField ---< PatientID
Now, step 3 is the tricky one. There are a couple of different methods.
1) You can write a script that loops over the found set and stores the IDs in the global field, something like this:
Go to Record / Request / Page [ First ]
Set Field [ GlobalField ; "" ]
Set Field [ GlobalField ; List ( GlobalField ; PatientID ) ]
Go to Record / Request / Page [ Next ; Exit after last ]
You'll have to run that script whenever you do a Find. A Script Trigger can be used to accomplish this, or you can run it manually via a button.
2) More sophisticated is to use a Custom Function to assemble the list. There's one on Brian Dunning's site that assembles the list for you (http://www.briandunning.com/cf/1093). However you'll need FileMaker Pro Advanced to insert it into your database. Once you do that, you can have the field automatically calculate the value using a global calculation.
Thanks for the quick response. Ill give it whirl.
Sent from my iPhone 5