Results 1 to 6 of 6
  1. #1
    Join Date
    Dec 2011
    Posts
    4

    Default Import / Export and Rules usind command line

    I have been checking the Automation with scripts section of the help manual. I actually want to compare files by applying mutiple rules. One scenario could be:

    1. Indicating key columns.
    2. Specify unimportant columns
    3. Apply decimal precision


    Is this possible using command line. I would want to have a detailed (HTML, csv etc) report. Highlighting mismatched.

    Also do we have a list of all possible commands that can be run through command line. The help manual do have a list of commands. Are they all or do we have more??


    I also want to import and export all my rules (could be multiple ) applied to a session, my tool settings etc etc . Is this possible through command line. If yes please share the sample code.

  2. #2
    Join Date
    Oct 2007
    Location
    Madison, WI
    Posts
    11,787

    Default

    Hello,

    All of the command line (and scripting commands) are documented in the Help file in near the bottom in the two chapters: Command Line Reference and Scripting Reference. There is some additional scripting info in the Using Beyond Compare -> Automating with Script (such as using command line parameters %1 %2 etc).

    We do not currently have a command for importing/exporting session settings on the command line. Script can only load saved Folder Compare sessions. As a workaround, you can save a Folder Compare sessions with specific child session settings, for example:

    Open a Folder Compare in the graphical interface.
    Set the Name Filter to show only the files you want to generate a report with.
    Save the Folder Compare session.
    Double click one of the file pairs to open a child Data Compare session.
    Set your Session Settings, and in the Session Setting dialog (under the Session menu), change the dropdown from "Use for this view only" to "Use for all files in parent session" (if same session settings can be used for all the current files, alternatively use "Use for these files in parent session").

    Close the child session and re-save the parent folder compare.

    To test, close out of BC3 and open it up again and reload your saved folder compare. Double clicking the file pair should apply the saved child settings automatically and compare them as you expect without needing additional tweaking.

    You can then use a script that loads the session, selects the file, and generates a report:
    load FolderCompareSessionName
    expand all
    select all.files
    data-report layout:side-by-side output-to:"c:\bcreport.txt"

    How does this work for you?

    Another alternative is to have a Portable Install of BC3 to run your scripts, and to manually alter the BCSettings.xml files in the portable install directory during the automated process.
    Aaron P Scooter Software

  3. #3
    Join Date
    Dec 2011
    Posts
    4

    Default

    Thanks Aaron.....I will test the solution given by you to find out whether it solve our issue or not.

    Please share details about portable install of BC...how can we install portable BC and how to use it ?

  4. #4
    Join Date
    Oct 2007
    Location
    Madison, WI
    Posts
    11,787

    Default

    Hello,

    A Portable Install is one of the options during the initial install wizard (when running the setup.exe file). You would install to a location on your harddrive (for example c:\beyondcompare) that has read and write access. All of the settings files (BCFileFormats.xml BCSessions.xml, etc) are stored in the same directory. It is designed to be a self contained folder, something that you would run from a USB thumb drive. It does not have access to the windows right-click shell extension because of this; to uninstall, you would simply delete the folder.
    Aaron P Scooter Software

  5. #5
    Join Date
    Jun 2017
    Posts
    2

    Default Set/Change Rules using Command line

    Hello,

    We have a requirement whether we can set/change the rules through command line.
    We have to setup different rules for different file sets. File sets are of the same type. We would not want to set up/change the rules in the system every time before running in command prompt as a batch.

    Thanks,
    Poonam

  6. #6
    Join Date
    Oct 2007
    Location
    Madison, WI
    Posts
    11,787

    Default

    Hello,

    Are the file names static? In that case you can have multiple formats setup in the File Formats dialog, with the file mask set to specific file names.
    Aaron P Scooter Software

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •