Jump to content

aparkssiskfs.com

Members
  • Posts

    9
  • Joined

Posts posted by aparkssiskfs.com

  1. 38 minutes ago, Dan Korn said:

    If you think about it, the total number of records doesn't change per-record, it's a job-level thing.  And it has to be calculated ahead of time, in a preprocessing step, and you obviously have to tell FusionPro to do that preprocessing at the start of the whole job.  FusionPro doesn't do preprocessing by default, as there is a bit of a time cost to it, but in cases like this, there's no other way to know for sure how many records will be composed.

    Some things can be examined and calculated at rule validation time, in the Rule Editor, like the values of fields, but other things have no context outside of a composition, like activating pages.  The Validate button in the editor is for convenience, to help in the development and debugging of rules, but ultimately, the composed output is what matters.

    Sure, glad to help.  You're part of a great community here.

    Thanks for for taking the time to explain all that! I agree, this is a great place.

  2. 21 hours ago, Dan Korn said:

    If you want the true number of total records, you can either use the $outputrecordnumber and $totalrecordcount variables in the Text Editor, or create a rule like so:

    return FusionPro.Composition.outputRecordNumber + " of " + FusionPro.Composition.totalRecordCount;

    But either way, you need to set the job to do preprocessing to determine the total number of record, in OnJobStart, like so:

    FusionPro.Composition.forcePreprocessing = true;

     

    20 hours ago, Dan Korn said:

    Any property of FusionPro.Composition is going to be valid at composition time, but not at rule validation time.  Compose the job and the output should be correct.

    Thank you Dan, that worked just how I needed it to.  One thing I did wrong, I was using OnRecordStart not OnJobStart - that makes a difference apparently (not sure why). I somewhat knew that some things validate during the composition but I didn't know that any property containing FusionPro.Composition happens during composing only.   I'm slowly learning FP, I have been teaching myself. Thanks for the help, I appreciate it.

  3. Hi Dan,

    I did what you said but it gives me 1 of 0. Not the quantity of the file? I will try again in the morning when I get back into the office but do you have any suggestions on what im missing? 

    When I validate the expression, it says, 1 of undefined

     

    Thanks for the response. 

  4. Hi,

    I'm just trying to get the total record count to print on my letter. Say I have 10 records in my file. I want each page to print as: 1 of 10, 2 of 10, 3 of 10...etc.

    This seems so simple but I'm having a hard time just figuring out the total count number. Thanks for any help.

  5. Help please!

    What I have going on...

    I have a file that has multiple Letter Codes. Only some of the letter codes need a label to be printed. So I have a rule OnRecordStart to give me the codes that need the label printed. Then the label setup has 2 records on a page.  I have the imposition setup to produce 2 records per page. That all has been working great.

    What I would like to be able to do is when composing get a pdf file per change in the letter code. So Lettercode1 would get its own pdf of the labels. Lettercode2 would be a separate pdf of the label and so on.

     

    I have tried writing this formula a couple different ways and it acts like it is going to work but when I view the output I get a message saying " Page Cant be found, 404 error" and the job log says " Job Config File: C:\FP Working DIR\1688573156\1688573156\producer-job-n.FPProducerConfig Composing record #1, input record 1 Sheet #1, record #1 The page size in this job differs from the page size in the imposition template. Results may be undesirable."

     

    here is the formula i have been bouncing around with:

    if(FieldChanged("LETTER CODE"))FusionPro.Composition.StartNewStack();FusionPro.Composition.OpenNewOutputFile();
    FusionPro.Composition.chunksBreakStacks=true;
    FusionPro.Composition.composeThisRecord=(Field("CERT AND LABEL")=="YES"||Field("CERT AND LABEL")=="Just Label & Notecard"||Field("CERT AND LABEL")=="JUST LABEL");

     

    Thank you.

     

     

  6. 19 hours ago, Dan Korn said:

    I would just do this and set composeThisRecord positively for the values you want, and negatively for others:

    FusionPro.Composition.composeThisRecord = (Field("LTRNM") == "CONFNL" || Field("LTRNM") == "Other Value");

    Which I think more closely matches your stated logic that "There are only 2 codes that will get this letter I'm composing."

    19 hours ago, Dan Korn said:
     = (Field("LTRNM") == "CONFNL" || Field("LTRNM") == "Other Value");

    Thank you so much! That worked like a charm! Appreciate the help. Have a great day.

  7. Having a bit of trouble. Trying to write an rule for when I'm composing my letter to skip all letter codes but the 2 different codes I need.  I currently have it setup to skip all but 1 code, which that works. But now I need to add in another code to the mix.  My file that I have attached will always have multiple different codes. There are only 2 codes that will get this letter I'm composing.   Here is my current rule:

    if(Field("LTRNM")!="CONFNL")FusionPro.Composition.composeThisRecord=false;

    I would think FP has a way to add in a 2nd code that i want to show up when composing. Any help would be great.  Also, I do have this setup as an event rule OnRecordStart. 

    Thanks 

×
×
  • Create New...