Jump to content

Alex Marshall

PTI Employee
  • Posts

    405
  • Joined

  • Days Won

    2

Posts posted by Alex Marshall

  1. You can inline any resource from your resource list by using the "resource" attribute of the "graphic" tag:

     

    return '<graphic resource="smile.eps">';

     

    or file:

     

    return '<graphic file="C:/smile.eps">';

     

    or

     

    if (Field("Logo") != "")

    {

    return '<graphic file="' + Field("Logo") + '">'; }

     

    Should put that image in without a problem -

  2. I just found the solution to this, seems to be related to an update that just came out recently to Acrobat DC, version 2017.012.20095

     

    https://forums.adobe.com/thread/2370866

     

    Under Preferences/General… The “Open Documents as new tabs in the same window” option needs to be turned on in order for FusionPro Tools to be available in the Customize Quick Tools window.

     

    You can then add the icons manually after performing this operation by selecting "View>>Show/Hide>>Toolbar Items>>Edit Current Toolset

    Select the Fusionpro option in the left pane and use the little arrowheads to add each Fusionpro icon to the toolbar. Click "Save".

  3. Add all the pages as a single PDF document. Then in FusionPro, select FusionPro>>Manage Pages>>>Page Usage. Name each page and set it to unused. Then create an Onrecordstart rule, Create Rules>>>New>>Callback>>OnRecordStart.

    The rule below can be simplified greatly by only activating the page you need, since all the pages are marked unused initially. So it can be reduced to this:

    if (Field("Addresses") == "1")

    FusionPro.Composition.SetBodyPageUsage("One", true);

    FusionPro.Composition.SetBodyPageUsage("back 1", true);

    if (Field("Addresses") == "2")

    FusionPro.Composition.SetBodyPageUsage("Two", true);

    FusionPro.Composition.SetBodyPageUsage("back 2", true);

    if (Field("Addresses") == "3")

    FusionPro.Composition.SetBodyPageUsage("Three", true);

    FusionPro.Composition.SetBodyPageUsage("back 3", true);

    if (Field("Addresses") == "4")

    FusionPro.Composition.SetBodyPageUsage("Four", true);

    FusionPro.Composition.SetBodyPageUsage("back 4", true);

    etc......

  4. If you want the whole frame to be hidden under certain circumstances, then name the frame and in the OnRecordStart rule hide it as appropriate.

     

    The code to hide a frame is simply this (in OnRecordStart)

     

    var frame=FindGraphicFrame("Frame1"); // replace Frame1 with the name of your frame –

    frame.suppress();

     

    Just put this code in an if block in OnRecordStart and it will hide the whole frame.

     

    Note that the doublequotes might have been changed to smart quotes in your email reader & might have to be changed to straight quotes in the rule editor.

  5. The encoding types are listed and documented in the following places:

     

    • In the FusionPro Rules Guide, in the section “How to use the DataMatrixbarcode() function” (page 102).

    • On the Building Blocks dialog, on the Objects tab, under Barcodes -> DataMatrixBarcode -> encoding.

    http://www.idautomation.com/barcode-faq/2d/data-matrix/#Encoding_Modes

     

    The Rule will look like this:

     

    var dataforbarcode = Field('First Name');

    var dmbarcodeobj = new DataMatrixBarcode;

    dmbarcodeobj.encodingmode = "C40";

    dmbarcodeobj.pointSize = 12;

    return dmbarcodeobj.Make(dataforbarcode);

  6. Creating a Data Matrix barcode is simple. You have to know which encoding mode you need and use it in the script.

    Here is the syntax:

     

    return MakeDataMatrixBarcode(DataToEncode, ProcessTilde, EncodingMode,PreferredFormat, PointSize, NoFontTag, Font)

     

    So click “Create Rules>>New(text)>>>Empty Rule. Give the Rule a name.

    Enter the code. Change the fieldname to match your data file.

     

    var dataforbarcode = Field(“mydatafield”);//etc…

    var dmbarcodeobj = new DataMatrixBarcode;

    dmbarcodeobj.encodingmode = "base256";

    dmbarcodeobj.pointSize = 12;

    return dmbarcodeobj.Make(dataforbarcode);

     

    • Data – The data that will be encoded. This can be one or more fields from your data, a result of another rule, etc.

    • Process Tilde – When set to "true", the format ~ddd is used to specify the ASCII code ofthe encoded character. For example, if the following text is entered in the Data field,

    ~029AB it will be encoded as GSAB where GS is a delimiter ASCII 29 character. This can be used in a single string to encode GS and RS characters (GS = ASCII 29 and RS =ASCII 30). Other commonly used ASCII codes are ~009 for a tab and ~013 which is a return function. These are useful when encoding multiple fields in a single symbol. Thedefault is false.

    • Encoding Mode –

    There are four encoding methods:

    • ASCII – encodes data that contains the first 128 ASCII characters.

    • C40 – encodes data that contains numeric and upper case characters.

    • TEXT –encodes data that contains both numeric and lowercase characters.

    • BASE256 – encodes 8 bit values.

     

     

    Now insert this Rule from the “Variable” drop box in the Variable Text Editor.

    Do not apply the font. The script will return the font. Test and compose.

  7. Transferring Layout and Rules from a previous job

     

    You need to make sure that if you are using FusionPro template

    Rules, select "FusionPro>>Edit Rules".

     

    Highlight the Rule and click "Convert To JavaScript".

    Click "Ok", "Ok" and save the template.

     

    Now compose one record. This will save the settings in the file

     

    This will ensure all the Rules will get transferred when using this

    solution

     

    If you are building an identical job that has the same layout,

    variable frames, rules, but different data file with the same field

    names, and would like to eliminate the need to reconstruct the

    FusionPro PDF; this tip will help.

     

    First, click "FusionPro", "Data Definition", "Wizard".

    Select "Import Data Source From Another Document".

    Click Next.

    Browse to the folder that contains the original pdf you want the

    information imported from.

    The name of the file will have a ".def" extension. Select it. Click

    "Open".

    Click "Finish"

    Click "FusionPro", "Advanced", "Import".

    A dialog box will appear with the following options preselected:

    Variable Layout, Colors, Style.

    Browse to the folder containing the original pdf .

×
×
  • Create New...