Jump to content

Recommended Posts

Posted

I have a project that I need to return multiple records into one text frame. I have FusionPro 10 and have chose multi line records. I chose the field change that I need and all seems in order. My problem is the rule I made to bring in the proper fields (which change from record to record) is and if/else statement in javascript with HTML tags. There will only be one record per person and my rule works just fine but I only get one entry per frame. The data takes up to a max of about 2 inches of length, but I want to fill my 10 inch frame with as many records as will fit, then go to a new frame (page). It seems like a need a for loop of some kind and have tried some of that with no success based on my previous posts. Any idea of what may need to be done to get my rule to return multiple records into one text frame?

 

 

FusionPro VDP Creator 10.0.26

Adobe Acrobat 2018

Mac OS X Yosemite Version 10.10.5

Posted

It's hard to say what you need to change in your rule without seeing your rule, or any of the rest of the job. But basically, you need to call the FusionPro.GetMultiLineRecords() function in a rule to get an ExternalDataFileEx object containing the lines of data for the record, then iterate through those records. Typically the rows of data from the multi-line record are put into a table.

 

Again, it's hard to be specific without seeing your job, or at least your data file, but you want to do something like this:

var XDF = FusionPro.GetMultiLineRecords();
var result = [];
for (var r = 1; r <= XDF.recordCount; r++)
   result.push(XDF.GetFieldValue(r, "SomeXDFFieldNameHere"));
return result.join("\n");

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...