Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×
The Claris Museum: The Vault of FileMaker Antiquities at Claris Engage 2025! ×

This topic is 3545 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted
 
Post:

Hi there

I have a scenario where I want to be able to upload multiple PDFs against a single parent record and then select which one is viewed.

I'm using a portal of the container table with the InsertFile script step to easily allow a user to add PDFs against a parent - that's not so much the issue.

However, I'm struggling to come up with a way to view/(stream) a given PDF as obviously they will not view live from a portal, only from a field placed directly on the layout, but the user instinct and therefore best use case is to select from the file manager portal I've built.

From the attached image, the right hand side shows container ID 11, which is document 1.

How can I have this change at the user's request to show container ID 12 or ID 13 which would in turn populate the viewing field with document 2 or document 3 respectively?

Thanks in advance

CapturePDFupload.PNG

Posted

You could create a script that gets the portal rows primary key of the child record and puts it into a global field in the parent table and attach it to a button in the portal.

Then make a join on the relationship graph that goes from the global parent to the child primary key.

Place a container field on the layout for the pdf from the child record across this relationship and youll display just the selected pdf.

 

Posted

Kris

I've gotten as far as grabbing the global variable of the child record but wasn't sure how to use it.  

This looks like a great idea, thanks for your help;)

Posted

Kris, 

Thanks for your help on this, I've got the relationships and variables set up.  I'm struggling on a daft point and hate to ask further...

I have 600 parent records with the PK_ID commencing at 1000.  On my script, I've gathered the portal row's PK ($$Variable 11) but I'm struggling to place it correctly on the parent field.  

The trouble I'm having is putting the $$Variable on the right record on the parent table.  I've tried GotoRecord but FM will obviously look at the found set (600 records) and navigate through there.  It doesn't look at the PK_ID (which in this case is 1010).

So, how do I get PK_ID's record updated with the $$variable 11?  

Thanks

Posted

Thanks for your help Kris, I've managed to script this, but still on the same relationship model you've suggested.

 

This topic is 3545 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.