Install-Configure: twsATSXL

Download and Install twsATSXL

Follow steps below to download and install twsATSXL:

  • Create a directory on any drive of your computer, i.e. D:\twsATSXL;
  • Download twsATSXL package from here and save it to the directory you just created;
  • Unzip this package to create a group of files and sub-directories under directory you just created, i.e. D:\twsATSXL;

Configure twsATSXL

Most ATSXL settings are presented on the CFG Worksheet.

The sample Excel spreadsheet file included with the package has all configrations set properly for you. So you do not worry about them at this moment, however you may need to change them later for your own trading strategy. Please refer to User Guide for details.

Configure and View twsATSXL Log Files

ATSXL produces the following three log files when it is running:

  • Primary log file - it keeps messages from ATSXL core components, including user message, warning or error if any.

    This file also keeps important messages from the following two log files, which provides a consolidated view on all events in sequence;
  • MSG log file - it keeps signals read from an external file, i.e. the signals generated from AmiBroker Exploration;
  • Trade log file - it keeps messages from Broker's trading API;

The location and file name can be configured on CFG Worksheet. Here are settings used in our sample twsATSXL spreadsheet:

Log_File = atsxl_core.log

MSG_Log_File = atsxl_msg.log

Trade_Log_File = atsxl_broker.log

You can view the file contents with any text editor or log monitoring software. Since these log files will be updated frequently by ATSXL, you should use a proper tool that:

  1. does not exclusively lock the file; and
  2. can move to the end of file easily (for your convenience);

We currently use BareTail and BareGrep from Bare Metal Software Pty Ltd. to view/tail the log files (using BareTail) and search certain contents (using BareGrep).

WWW.ATSXL.COM is not affiliated with the vendor of the above mentioned software. It is recommended here simply because the software meets our needs and we have used them for years.

Initial Check for Updates

For the first time, when you open a spreadsheet for ATSXL, and click [Load ATSXL] button on the CFG Worksheet, ATSXL will prompt you to check if there are bug fixes or updates available.


Let's use twsATSXL.xls as an example:

Please save and exit all Excel spreadsheets, then run the batch script update_ATSXL.bat under your ATSXL directory (double click it) or run it in a Command window.


The batch script will create a unique time stamped sub-directory (i.e. Backup_2013101309453012), copy all critical files along with your Excel spreadsheets into this directory, then start an automatic updater. You simply follow screen instructions from there.

A log file ATSXL_check_update.log will be updated with a summary of this update activity and the name of the backup directory if created.

If you prefer to not create a backup directory, you may run batch script update_ATSXL_NO_BACKUP.bat instead, which is a wrapper of update_ATSXL.bat. For example:


WARNING: It is not recommended to skip this backup step.

This backup created prior to any updates provides a way that you can roll back to previous version if something went wrong. You also get a chance to keep existing Excel spreadsheets with multiple versions that could be useful some time later. You can delete these backup directories when everything is confirmed OK.

You may run this check and update batch script at any time. ATSXL will remind you to run it once every three weeks to make sure you receive the most recent updates.

Load ATSXL Add-in into Excel

You now have the latest ATSXL after initial check and update from previous step.

Open twsATSXL.xls spreadsheet, and click Load ATSXL button on the CFG Worksheet, ATSXL Add-in will be loaded into Excel and creates a menu named twsATSXL on Excel's menu bar. Click the only sub-menu item About to display a small window with twsATSXL's version and website link.

ATSXL Add-in is loaded into twsATSXL.xls spreadsheet successfully if you see similar screen shown as below: