Announcement

Collapse
No announcement yet.

Fatal Scripting Error: Unable to load base folder

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Fatal Scripting Error: Unable to load base folder

    Hello All,

    I have created a script as below:

    log verbose "C:\scripts\Synclog.txt"
    load mpcu
    filter cutoff:<1days
    Select left.files
    Copy left->right

    when i run the above script from the command line:
    BComp.com @"C:\scripts\bc4script.txt" (either with or without double quotes)

    It runs properly, and copies the files to the proper location.

    when i run it within the task scheduler i get the following message:

    8/13/2018 5:34:40 PM >> log verbose "C:\scripts\Synclog.txt"
    8/13/2018 5:34:40 PM >> load mpcu
    8/13/2018 5:34:40 PM Load comparison: <->
    8/13/2018 5:34:40 PM Fatal Scripting Error: Unable to load base folder
    8/13/2018 5:34:40 PM Script completed in 0.02 seconds

    I have uploaded the settings from the task scheduler run screen

    I have tried the variables to use the bcomp.com or beyond.exe as exectuble.
    Tried with quotes or no quotes on the arguments field.
    Tried with optional start in field.

    All give me the same results.

    The "left location" is an UNC path to another server, the rights are correct and the service account has full rights.

    Any help is greatly appreciated.

    thanks,
    Attached Files

  • #2
    Hello,

    If the script is running as a different Windows User account, then it would have separate settings and not have access to the saved Session name. To quickly troubleshoot, I would recommend loading the paths as part of the load command, unless the Session has other saved session settings you need to set (they would also need to be added to the script).

    Or, if you create a Portable Install using the setup.exe to a globally accessible location (such as C:\Tools\BC4\Bcompare.exe), then any user (graphical or scripted) would run with the same settings using this install. To bring over the main install's settings, use the Tools menu -> Export to create an exported BCSettings.bcpkg file, and import it in the Portable Install's Tools menu -> Import.
    Aaron P Scooter Software

    Comment


    • #3
      Thank you Aaron,

      you are correct, the service account could not load the session name. i used the admin account to run the task and it worked perfectly.
      If i wan to add the paths to the load command what would be the syntax? and would that work for a comparison and then filter?

      thanks,

      Comment


      • #4
        Use the following syntax to load folders by name rather than using a saved session:

        load c:\folder1 \\server\share\folder1
        Chris K Scooter Software

        Comment


        • #5
          Hello,

          Yes, it could work. The Session potentially loads more than just paths (filters, comparison criteria, other items in the Session Settings dialog). If you only need the folders, then use Chris' command. If you need more, there are some script commands which can also act as some of the Session Settings, such as:

          log verbose "C:\scripts\Synclog.txt"
          filter cutoff:<1days
          load c:\folder1 \\server\share\folder1
          expand all
          folder-report layout:side-by-side output-to:"c:\reports\bcreport.html" output-options:html-color


          Before, you can set the filter after loading the session since the act of loading the session import's that session's filtering (and following filter commands then add or override those). By loading just folders, you can filter ahead of time, which then makes the load command slightly faster since the filters stay in effect during that load and the comparison only runs on the applicable "visible" items. If your saved session had other saved settings, you'd need to find and re-implement them in scripting as well. Hence, above, I recommend generating the report first to see what the comparison looks like, note the different items and what would be copied, before committing the action.
          Aaron P Scooter Software

          Comment

          Working...
          X